Replace the shared MOCK_* fixtures with factories

A frozen shared constant forces a test needing one different field to
either mutate shared state, leaking into every other test, or spread it
by hand. The make*(overrides) factories cover both cases and were already
doing the same job, so the constants were redundant.

MOCK_PARENT_A and MOCK_PARENT_B were distinct identities that partner
tests tell apart, so their uuid and name are now passed explicitly at
each call site rather than left to a factory default -- the values those
tests depend on stay visible where they are used.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RXMhc9nT6sNz1SL4j8dznL
This commit is contained in:
2026-09-15 07:47:34 +02:00
parent 46e89a4359
commit 5d9ac5024a
3 changed files with 14 additions and 22 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
/**
* Barrel for all typed test fixtures. Import from here:
*
* import { makeWorkspaceOverview, makePlanProposal, MOCK_WORKSPACE } from '../../tests/fixtures'
* import { makeWorkspaceOverview, makePlanProposal, makeWorkspace } from '../../tests/fixtures'
*
* See the sibling files for what each group covers:
* - mockData.ts domain entities (Workspace, PersonalData, Child, VacationDays,