mirror of
https://github.com/moltbot/moltbot.git
synced 2026-05-13 23:56:07 +00:00
test: tighten command config cleanup assertions
This commit is contained in:
@@ -455,7 +455,7 @@ describe("channels command", () => {
|
||||
|
||||
const next = await addAlertsTelegramAccount("alerts-token");
|
||||
expect(next.channels?.telegram?.enabled).toBe(true);
|
||||
expect(next.channels?.telegram?.accounts?.default).toEqual({});
|
||||
expect(next.channels?.telegram?.accounts?.default).toStrictEqual({});
|
||||
expect(next.channels?.telegram?.accounts?.alerts?.botToken).toBe("alerts-token");
|
||||
});
|
||||
|
||||
|
||||
@@ -29,6 +29,6 @@ describe("doctor config analysis helpers", () => {
|
||||
} as never);
|
||||
expect(result.removed).toContain("unexpected");
|
||||
expect((result.config as Record<string, unknown>).unexpected).toBeUndefined();
|
||||
expect((result.config as Record<string, unknown>).hooks).toEqual({});
|
||||
expect((result.config as Record<string, unknown>).hooks).toStrictEqual({});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -351,7 +351,7 @@ describe("legacy migrate sandbox scope aliases", () => {
|
||||
"Removed agents.list.0.agentRuntime; runtime is now provider/model scoped.",
|
||||
]),
|
||||
);
|
||||
expect(res.config?.agents?.defaults).toEqual({});
|
||||
expect(res.config?.agents?.defaults).toStrictEqual({});
|
||||
expect(res.config?.agents?.list?.[0]).toEqual({
|
||||
id: "reviewer",
|
||||
});
|
||||
|
||||
@@ -264,7 +264,7 @@ describe("doctor stale plugin config helpers", () => {
|
||||
},
|
||||
});
|
||||
expect(result.config.agents?.defaults?.heartbeat).toEqual({ every: "30m" });
|
||||
expect(result.config.agents?.list?.[0]?.heartbeat).toEqual({});
|
||||
expect(result.config.agents?.list?.[0]?.heartbeat).toStrictEqual({});
|
||||
expect(result.config.agents?.list?.[1]?.heartbeat).toEqual({ target: "telegram" });
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user