test(06-07): failing turn-card cron suite GC1-GC8 + CS7 card-copy gate (RED)
- GC1-GC7: PURE projectTurnCards behavior — projection math, cadence table, dead-trip gate, 4-line caption anatomy, street-bearing DEFAULT (D-12) vs bare-verb degradation, real makeStreetAt against the committed mini-graph - GC8: the pure-module structural law (no console, routing-workspace imports, nameId street hop, zero KV writes) - CS7 in commands.test.mjs pins the 21 UI-SPEC turn-card keys in en + ms
This commit is contained in:
@@ -202,3 +202,63 @@ test("CS6 D-04: command stack registers exactly /start /mula /help /privacy /pri
|
||||
"the command stack must be exactly the phase surface (D-04; no drift, no extras)",
|
||||
);
|
||||
});
|
||||
|
||||
/* ————— CS7 — GUID-05 turn-card copy gate (06-07; D-12/D-13, UI-SPEC verbatim) ————— */
|
||||
|
||||
test("CS7 D-12/D-13: the 21 turn-card keys exist verbatim in en + ms — 8 street-bearing verbs, 8 bare degradation verbs, street fallback, ETA template, honesty line, OPEN button", () => {
|
||||
const expected = {
|
||||
en: {
|
||||
cardActionDepart: "DEPART",
|
||||
cardActionStraight: "CONTINUE ON",
|
||||
cardActionLeft: "TURN LEFT ONTO",
|
||||
cardActionRight: "TURN RIGHT ONTO",
|
||||
cardActionSlightLeft: "KEEP LEFT ONTO",
|
||||
cardActionSlightRight: "KEEP RIGHT ONTO",
|
||||
cardActionUturn: "MAKE A U-TURN ONTO",
|
||||
cardActionArrive: "ARRIVE AT",
|
||||
cardActionBareDepart: "DEPART",
|
||||
cardActionBareStraight: "CONTINUE",
|
||||
cardActionBareLeft: "TURN LEFT",
|
||||
cardActionBareRight: "TURN RIGHT",
|
||||
cardActionBareSlightLeft: "KEEP LEFT",
|
||||
cardActionBareSlightRight: "KEEP RIGHT",
|
||||
cardActionBareUturn: "MAKE A U-TURN",
|
||||
cardActionBareArrive: "ARRIVE",
|
||||
cardStreetUnnamed: "UNNAMED ROAD",
|
||||
cardEtaTemplate: "ETA {time} · {km} KM LEFT",
|
||||
cardHonesty: "Best-effort projection — updates while the app is minimized.",
|
||||
cardOpenButton: "OPEN GUIDANCE",
|
||||
},
|
||||
ms: {
|
||||
cardActionDepart: "MULA",
|
||||
cardActionStraight: "TERUS KE",
|
||||
cardActionLeft: "BELOK KIRI KE",
|
||||
cardActionRight: "BELOK KANAN KE",
|
||||
cardActionSlightLeft: "SEDAKIT KIRI KE",
|
||||
cardActionSlightRight: "SEDAKIT KANAN KE",
|
||||
cardActionUturn: "BUAT PUSARAN KE",
|
||||
cardActionArrive: "TIBA DI",
|
||||
cardActionBareDepart: "MULA",
|
||||
cardActionBareStraight: "TERUS",
|
||||
cardActionBareLeft: "BELOK KIRI",
|
||||
cardActionBareRight: "BELOK KANAN",
|
||||
cardActionBareSlightLeft: "SEDAKIT KIRI",
|
||||
cardActionBareSlightRight: "SEDAKIT KANAN",
|
||||
cardActionBareUturn: "BUAT PUSARAN",
|
||||
cardActionBareArrive: "TIBA",
|
||||
cardStreetUnnamed: "JALAN TANPA NAMA",
|
||||
cardEtaTemplate: "ETA {masa} · {km} KM LAGI",
|
||||
cardHonesty: "Unjuran cuba terbaik — dikemas kini semasa aplikasi diminimumkan.",
|
||||
cardOpenButton: "BUKA PANDUAN",
|
||||
},
|
||||
};
|
||||
for (const locale of ["en", "ms"]) {
|
||||
for (const [key, value] of Object.entries(expected[locale])) {
|
||||
assert.equal(
|
||||
strings[locale][key],
|
||||
value,
|
||||
`${locale}.${key} must carry the UI-SPEC verbatim turn-card value`,
|
||||
);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user