Stub the custom category read in the export route tests

The full backup now reads the account's own medication categories, and
three route tests that drive the payload builder against a mocked client
had no delegate for it.
This commit is contained in:
Marc-André Bombeck committed 2026-10-03 21:59:42 +02:00
1 parent 802759df02
commit b7458f0607
3 files changed
+12

No files matched your search

@@ -12,6 +12,9 @@ vi.mock("@/lib/db", () => ({
prisma: {
measurement: { findMany: vi.fn().mockResolvedValue([]) },
medication: { findMany: vi.fn().mockResolvedValue([]) },
// v1.40 — the custom medication categories the backup carries.
medicationCategoryLabel: { findMany: vi.fn().mockResolvedValue([]) },
medicationCategoryAssignment: { findMany: vi.fn().mockResolvedValue([]) },
medicationIntakeEvent: { findMany: vi.fn().mockResolvedValue([]) },
moodEntry: { findMany: vi.fn().mockResolvedValue([]) },
moodTag: { findMany: vi.fn().mockResolvedValue([]) },