From 0a540208e1ba1bfd91b641310ace6cfbbceb6004 Mon Sep 17 00:00:00 2001 From: Lucas Winther Date: Fri, 30 Oct 2026 21:19:08 +0100 Subject: [PATCH] test(server): silence the broken fixture plugin warning Co-Authored-By: Claude Opus 5.5 --- apps/server/test/api.test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/server/test/api.test.ts b/apps/server/test/api.test.ts index 1085897..e18fa97 100644 --- a/apps/server/test/api.test.ts +++ b/apps/server/test/api.test.ts @@ -1,4 +1,4 @@ -import { afterEach, beforeEach, describe, expect, test } from "bun:test"; +import { afterEach, beforeEach, describe, expect, spyOn, test } from "bun:test"; import { mkdtemp, rm } from "node:fs/promises"; import { tmpdir } from "node:os"; import { join } from "node:path"; @@ -10,7 +10,10 @@ import { sessionCookie as buildSessionCookie } from "../src/http.ts"; import { safeFilename } from "../src/routes/attachments.ts"; const ECHO_DIR = join(import.meta.dir, "../../../packages/core/test/fixtures/plugins"); +// The fixture dir also holds a deliberately broken plugin; silence its load warning. +const warn = spyOn(console, "warn").mockImplementation(() => {}); const registry: PluginRegistry = await loadPlugins([ECHO_DIR]); +warn.mockRestore(); const BASE = "http://localhost/api/v1"; type App = ReturnType;