Problem
tests/unit/challenge-parity.test.ts guards the challenge count in README.md and EDUCATORS.md, but 2 of the 4 places that state it slip through:
README.md:13 — the hero line, the first number a visitor reads: 36 challenges across <b>web, API, ...</b>. Neither guard regex matches it (no "CTF", no "chapters").
EDUCATORS.md:187 — .match() returns only the first hit, so only EDUCATORS.md:19 is actually asserted.
Adding the 37th challenge therefore passes CI with a stale "36" in the README headline.
Current guards
tests/unit/challenge-parity.test.ts:366 and :381
readme.match(/(\d+) CTF challenges across (\d+) chapters/); // → README.md:168 ✅
readme.match(/(\d+) chapters, (\d+) flags/); // → README.md:186 ✅
educators.match(/all (\d+) challenges/); // → EDUCATORS.md:19 only
Fix
- Add an assertion covering the README hero line.
- Switch the
EDUCATORS.md assertion to matchAll so every occurrence is checked.
⚠️ README.md:170 reads "8 tasks and 7 flags" about the TryHackMe room — that is not the challenge count. A blanket /(\d+) flags/ assertion will fail on it.
Acceptance
Commenting out one entry in prisma/flags.ts makes npm run test:unit fail and name both README.md:13 and EDUCATORS.md:187.
Problem
tests/unit/challenge-parity.test.tsguards the challenge count inREADME.mdandEDUCATORS.md, but 2 of the 4 places that state it slip through:README.md:13— the hero line, the first number a visitor reads:36 challenges across <b>web, API, ...</b>. Neither guard regex matches it (no "CTF", no "chapters").EDUCATORS.md:187—.match()returns only the first hit, so onlyEDUCATORS.md:19is actually asserted.Adding the 37th challenge therefore passes CI with a stale "36" in the README headline.
Current guards
tests/unit/challenge-parity.test.ts:366and:381Fix
EDUCATORS.mdassertion tomatchAllso every occurrence is checked.README.md:170reads "8 tasks and 7 flags" about the TryHackMe room — that is not the challenge count. A blanket/(\d+) flags/assertion will fail on it.Acceptance
Commenting out one entry in
prisma/flags.tsmakesnpm run test:unitfail and name bothREADME.md:13andEDUCATORS.md:187.