From 21c698a6169658f6f7ffabca407bf817601479cb Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Fri, 11 Sep 2026 15:00:38 -0400 Subject: [PATCH] test(web): give the admin page mock the fingerprint coverage query b8855b48 made the admin overview page create a fingerprint coverage query, but admin.test.ts mocks $lib/api/admin with an explicit factory that only returned the cover coverage query. Every test that renders the page threw on the missing export (run 6512, 11 failures). The mock now returns it in the same empty-store shape, so the gauge stays hidden in these tests the way the cover gauge does. Co-Authored-By: Claude Opus 5 (1M context) Claude-Session: https://claude.ai/code/session_01SQ31KQpYbStyK5y58UmPLH --- web/src/routes/admin/admin.test.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/web/src/routes/admin/admin.test.ts b/web/src/routes/admin/admin.test.ts index 35f4dfdf..d80205f0 100644 --- a/web/src/routes/admin/admin.test.ts +++ b/web/src/routes/admin/admin.test.ts @@ -35,6 +35,12 @@ vi.mock('$lib/api/admin', async () => { isPending: false, isError: false }), + createFingerprintCoverageQuery: () => + readable({ + data: undefined, + isPending: false, + isError: false + }), approveRequest: vi.fn().mockResolvedValue({}), rejectRequest: vi.fn().mockResolvedValue({}), resolveQuarantine: vi.fn().mockResolvedValue({}),