Suppress expected console.error output in error-path tests
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -215,9 +215,13 @@ describe("filesStore", () => {
|
||||
});
|
||||
|
||||
it("returns early for invalid id without throwing", async () => {
|
||||
const spy = vi.spyOn(console, "error").mockImplementation(() => {});
|
||||
|
||||
await expect(store.deleteFile("log", null)).resolves.toBeUndefined();
|
||||
|
||||
expect(mockDelete).not.toHaveBeenCalled();
|
||||
expect(spy).toHaveBeenCalledWith("Delete File API Error: invalid id");
|
||||
spy.mockRestore();
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user