G Destination gate
Run every check in order from a clean checkout of experiment/redline with
npm ci && npm --prefix service ci && npm --prefix test/fixtures/site ci && npm --prefix site ci.
A check passes only with the stated output. Record each result in
STATUS.md under task G. The verifier re-runs all of them.
G1 Unit tests
npm test 2>&1 | grep -E '^ℹ (pass|fail) ' # fail 0; pass >= 43 + the new tests
Then confirm every named test exists and passed (each command prints the number shown):
| Command | Expected |
|---|---|
npm test 2>&1 | grep -c '^✔ mock gitlab' | 7 |
npm test 2>&1 | grep -c '^✔ fixture' | 2 |
npm test 2>&1 | grep -c '^✔ gitlab-oauth mode|^✔ cookie security|^✔ environment validation' | 6 |
npm test 2>&1 | grep -c '^✔ health reports|^✔ document state responds|^✔ document state keeps' | 5 |
npm test 2>&1 | grep -c '^✔ benchmark harness' | 2 |
npm test 2>&1 | grep -c '^✔ index |^✔ paths outside|^✔ dirty and untracked|^✔ warm index|^✔ index cache' | 7 |
npm test 2>&1 | grep -c '^✔ enriched history' | 4 |
npm test 2>&1 | grep -c '^✔ semantic|^✔ word diff' | 6 |
npx prettier --check . && npx eslint . && npx tsc --noEmit; echo $? | 0 |
npm test 2>&1 | grep -c '^✔ remark plugin' | 3 |
npm test 2>&1 | grep -c '^✔ document history|^✔ document state exposes|^✔ block changes are null' | 4 |
npm test 2>&1 | grep -c '^✔ classifies|^✔ derives|^✔ messages exist|^✔ changed blocks since' | 8 |
npm test 2>&1 | grep -c 'validates against|fails validation' | 5 |
npm test 2>&1 | grep -c '^✔ store' | 7 |
npm test 2>&1 | grep -c '^✔ components' | 2 |
npm test 2>&1 | grep -c '^✔ production experiment environment' | 2 |
npm test 2>&1 | grep -c '^✔ smoke' | 3 |
npm test 2>&1 | grep -c '^✔ experiment report' | 2 |
npm test 2>&1 | grep -c '^✔ service url resolves|^✔ dashboard' | 3 |
npm test 2>&1 | grep -c '^✔ static handler|^✔ node server serves' | 4 |
npm test 2>&1 | grep -c '^✔ compose qa service|^✔ experiment env examples' | 2 |
npm test 2>&1 | grep -c '^✔ semantic delete operations|^✔ remark plugin stamps block fingerprints|^✔ document version|^✔ version payload' | 5 |
G2 Build-time bound
npm run bench:history -- --pages 300 --commits 1200 --warm
Two JSON lines. Line 1: "pages":300, "indexed":true, "gitCalls" ≤ 8.
Line 2: "indexSource":"cache", "gitCalls" ≤ 7.
npm run bench:history -- --pages 3 --commits 1200
"gitCalls" equal to line 1 above.
G3 Contract
Covered by G1 (validates against ×3 and fails validation ×1), plus:
grep -c "gitlab-unreachable" contracts/openapi.yaml # >= 1
grep -c "blockHistory" contracts/openapi.yaml # >= 1
G4 End to end
npm run test:e2e 2>&1 | tail -3 # "30 passed"
Spec files present: health, reachability, static-fallback, oauth,
redline, changed-since, comments, dashboard, timeline, inline-comments (ls test/e2e/*.spec.js | wc -l prints 10).
The live spec exists: ls test/live/live.spec.js.
G5 Pipeline
The latest pipeline on experiment/redline is green with jobs
version-calver, gitleaks, prettier, eslint, tsc, test,
astro_compatibility (both), e2e, site, and the container job’s log
shows /app/site/index.html in the image.
glab ci status --branch experiment/redline # every job passed
G6 Static surface unchanged for existing consumers
npm pack --dry-run 2>&1 | grep -E ' semantic.js|remark-redline-blocks.js|GitRedline.astro|GitChangedSince.astro' | wc -l # 4
node -e "import('./index.js').then(m => console.log(['getGitMeta','getGitMetaEnhanced','createGitHistoryViewModel','createRedlineClient','decorateDocumentChanges','parseDocumentBlocks','diffWords','classifyRedlineFailure','createRedlineStore','applyInlineRedline','changedBlocksSince'].every(k => typeof m[k] === 'function')))" # true
G7 Deployed service, QA and production (evidence from T6.7)
STATUS.md holds, for T6.7 and for each of https://qa-yqa.fio.sh and
https://yqa.fio.sh: on-net smoke output with "state" of live or
connect-required and exit 0; off-net smoke output offline-network and
exit 2; npm run test:live output 4 passed; the image tag; the date.
G8 Stage 1 demonstration (evidence from T6.7)
STATUS.md holds: the URL of a real merge request on fio-redline changing
a paragraph under kb/, shown inline on QA; the URL of the
[Document Review] kb/… issue holding an anchored comment made on QA under
the commenter’s own GitLab account; a screenshot path.
G9 Commit hygiene and recorded refactors
git log main..experiment/redline --format=%B | grep -ci 'co-authored-by\|generated with' # 0
git log main..experiment/redline --format=%B | grep -c '^Plan-Task: ' # equals the number of non-style commits
grep -c 'interim' STATUS.md # if > 0, a propagation task exists in B3 and is done
Every unforeseen refactor is listed in a STATUS.md note. The verifier reads
those notes before the code.
G10 Lifecycle records
ls kb/lifecycle/decisions/ADR-*.md | wc -l # 8
grep -c '^## TD-' kb/lifecycle/tech-debt.md # 8 (7 from T6.6, TD-008 from T6.8)
After the gate
The gate closes Stage 1. The usage measurement belongs to Stage 2: thirty days after YYZ adoption (B5, once re-planned) is deployed, the operator runs on the host:
docker logs fio-redline 2>&1 | node scripts/experiment-report.js --since <deploy date>
The bet is alive when actors >= 3 and writes >= 20. Otherwise the service
is frozen: WRITE_ENABLED=false, features.review=false in YYZ, and this
plan is closed with the report attached.