mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-08 12:32:43 +00:00
Point the score-config contract test at the pillar list that survived
Two branches met here. One retired the fitness pillar and renamed the test's pillar list accordingly; the other, written against the eight-pillar world, referred to it by its old name and its old count. The merge kept the new declaration and the old references, so nothing compiled. The name carried the count, which is why the collision was visible at all. There are seven now.
This commit is contained in:
1 parent
a830e8a9d3
commit
368eb44439
2 files changed
+4
-4
No files matched your search
@@ -455,10 +455,10 @@ describe("the published contract matches what the route serves", () => {
|
||||
// Body that fails validation.
|
||||
await record({ pillars: ["NOT_A_PILLAR"] });
|
||||
// Present-but-unparseable base token.
|
||||
await record({ pillars: ALL_EIGHT, baseUpdatedAt: null });
|
||||
await record({ pillars: ALL_PILLARS, baseUpdatedAt: null });
|
||||
// Stale base token.
|
||||
await record(
|
||||
{ pillars: ALL_EIGHT, baseUpdatedAt: "2026-07-24T08:00:00.000Z" },
|
||||
{ pillars: ALL_PILLARS, baseUpdatedAt: "2026-07-24T08:00:00.000Z" },
|
||||
true,
|
||||
);
|
||||
return byStatus;
|
||||
@@ -506,7 +506,7 @@ describe("the published contract matches what the route serves", () => {
|
||||
vi.mocked(prisma.user.updateMany).mockResolvedValue({ count: 1 } as never);
|
||||
|
||||
const res = await (PATCH as (r: Request) => Promise<Response>)(
|
||||
mkPatch({ pillars: ALL_EIGHT }),
|
||||
mkPatch({ pillars: ALL_PILLARS }),
|
||||
);
|
||||
const env = (await res.json()) as { data: ResolvedBody };
|
||||
expect(res.status).toBe(200);
|
||||
|
||||
@@ -22,7 +22,7 @@ export const SCORE_VERSION = 3 as const;
|
||||
/**
|
||||
* The pillars a score can be built from.
|
||||
*
|
||||
* v1.35.1 — FITNESS is gone. The schema records VO₂max but cannot tell a
|
||||
* v1.35.2 — FITNESS is gone. The schema records VO₂max but cannot tell a
|
||||
* measured test apart from a device estimate, so every FITNESS row
|
||||
* reached the scorer unproven and was refused: the pillar had never once
|
||||
* produced a value on any account. A pillar that cannot score is not a
|
||||
|
||||
Reference in new issue
Block a user