test: stabilize CLI hint assertions under CLAWDBOT_PROFILE (#2507)
This commit is contained in:
@@ -47,7 +47,9 @@ describe("gateway tool", () => {
|
||||
payload?: { kind?: string; doctorHint?: string | null };
|
||||
};
|
||||
expect(parsed.payload?.kind).toBe("restart");
|
||||
expect(parsed.payload?.doctorHint).toBe("Run: clawdbot doctor --non-interactive");
|
||||
expect(parsed.payload?.doctorHint).toBe(
|
||||
"Run: clawdbot --profile isolated doctor --non-interactive",
|
||||
);
|
||||
|
||||
expect(kill).not.toHaveBeenCalled();
|
||||
await vi.runAllTimersAsync();
|
||||
|
||||
@@ -104,7 +104,7 @@ describe("acquireSessionWriteLock", () => {
|
||||
});
|
||||
it("cleans up locks on SIGINT without removing other handlers", async () => {
|
||||
const root = await fs.mkdtemp(path.join(os.tmpdir(), "clawdbot-lock-"));
|
||||
const originalKill = process.kill.bind(process);
|
||||
const originalKill = process.kill.bind(process) as typeof process.kill;
|
||||
const killCalls: Array<NodeJS.Signals | undefined> = [];
|
||||
let otherHandlerCalled = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user