test: Silence superfluous console output during test runs (#2540)

This commit is contained in:
Dermot Duffy
2026-06-30 17:45:13 -07:00
committed by dermotduffy
parent 921d45e577
commit fcef48e75a
8 changed files with 23 additions and 25 deletions
+1 -1
View File
@@ -46,7 +46,7 @@ describe('task utilities', () => {
task.render.mockImplementation((renderers) =>
renderers.error?.(new Error('test error')),
);
const consoleSpy = vi.spyOn(console, 'warn').mockImplementation(() => undefined);
const consoleSpy = vi.spyOn(console, 'warn');
const errorFunc = vi.fn().mockReturnValue(html`error`);
const result = renderTask(task, (r) => html`${r}`, { errorFunc });