test(infra): assert dotenv logger warning sink

Co-authored-by: openclaw-clawsweeper[bot] <280122609+openclaw-clawsweeper[bot]@users.noreply.github.com>
This commit is contained in:
clawsweeper[bot]
2026-04-29 19:55:18 +01:00
committed by GitHub
parent e69da9d578
commit fc2d957923

View File

@@ -188,12 +188,12 @@ describe("loadDotEnv", () => {
);
vi.spyOn(process, "cwd").mockReturnValue(cwdDir);
const warn = vi.spyOn(console, "warn").mockImplementation(() => undefined);
loggerMocks.warn.mockClear();
loadDotEnv({ quiet: true });
expect(process.env.FOO).toBe("from-shell");
expect(warn).not.toHaveBeenCalled();
expect(loggerMocks.warn).not.toHaveBeenCalled();
});
});
});