mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-05 04:22:33 +00:00
refactor: rename clawdbot to moltbot with legacy compat
This commit is contained in:
@@ -14,7 +14,7 @@ vi.mock("../agents/pi-embedded.js", () => ({
|
||||
}));
|
||||
|
||||
import { resetInboundDedupe } from "../auto-reply/reply/inbound-dedupe.js";
|
||||
import type { ClawdbotConfig } from "../config/config.js";
|
||||
import type { MoltbotConfig } from "../config/config.js";
|
||||
import { monitorWebChannel } from "./auto-reply.js";
|
||||
import { resetLoadConfigMock, setLoadConfigMock } from "./test-helpers.js";
|
||||
|
||||
@@ -46,7 +46,7 @@ const rmDirWithRetries = async (dir: string): Promise<void> => {
|
||||
beforeEach(async () => {
|
||||
resetInboundDedupe();
|
||||
previousHome = process.env.HOME;
|
||||
tempHome = await fs.mkdtemp(path.join(os.tmpdir(), "clawdbot-web-home-"));
|
||||
tempHome = await fs.mkdtemp(path.join(os.tmpdir(), "moltbot-web-home-"));
|
||||
process.env.HOME = tempHome;
|
||||
});
|
||||
|
||||
@@ -61,7 +61,7 @@ afterEach(async () => {
|
||||
const _makeSessionStore = async (
|
||||
entries: Record<string, unknown> = {},
|
||||
): Promise<{ storePath: string; cleanup: () => Promise<void> }> => {
|
||||
const dir = await fs.mkdtemp(path.join(os.tmpdir(), "clawdbot-session-"));
|
||||
const dir = await fs.mkdtemp(path.join(os.tmpdir(), "moltbot-session-"));
|
||||
const storePath = path.join(dir, "sessions.json");
|
||||
await fs.writeFile(storePath, JSON.stringify(entries));
|
||||
const cleanup = async () => {
|
||||
@@ -104,7 +104,7 @@ describe("broadcast groups", () => {
|
||||
strategy: "sequential",
|
||||
"+1000": ["alfred", "baerbel"],
|
||||
},
|
||||
} satisfies ClawdbotConfig);
|
||||
} satisfies MoltbotConfig);
|
||||
|
||||
const sendMedia = vi.fn();
|
||||
const reply = vi.fn().mockResolvedValue(undefined);
|
||||
@@ -158,7 +158,7 @@ describe("broadcast groups", () => {
|
||||
strategy: "sequential",
|
||||
"123@g.us": ["alfred", "baerbel"],
|
||||
},
|
||||
} satisfies ClawdbotConfig);
|
||||
} satisfies MoltbotConfig);
|
||||
|
||||
const sendMedia = vi.fn();
|
||||
const reply = vi.fn().mockResolvedValue(undefined);
|
||||
@@ -269,7 +269,7 @@ describe("broadcast groups", () => {
|
||||
strategy: "parallel",
|
||||
"+1000": ["alfred", "baerbel"],
|
||||
},
|
||||
} satisfies ClawdbotConfig);
|
||||
} satisfies MoltbotConfig);
|
||||
|
||||
const sendMedia = vi.fn();
|
||||
const reply = vi.fn().mockResolvedValue(undefined);
|
||||
|
||||
Reference in New Issue
Block a user