Skip to content

Commit 4c8120d

Browse files
Prithvi-Webclaude
andcommitted
test(docs): once the Track U plan records the gate run, the roadmap's gate conditions may say what the run found in their own words, and only "has not been run" is refused (review F3.4)
The F2.1 test's branch for a gate the plan records as anything but exactly "not run" could not be passed by a true sentence. It still required each condition (problem 3, step 13, the gate's section, the Definition-of-Done row) to say "whether 5.2.0 waits for it is your decision". So "(5.2.0: the gate was run on 8 Oct 2026 and U1, U2 and U3 were met; ...)" failed. A row of "not run yet" also took that branch, and then failed the Release bullet for saying the gate had not been run, which was true (both recorded as pre34- runs). "not run" is now matched as a word, so "not run yet" and "not run (...)" still mean not run. For a gate recorded as run (passed or not met), each condition must still say how the gate stands for the release, as a "(5.2.0: ... gate ...)" note in its own words, and must not say that it has not been run. The not-run branch is unchanged. Scenarios: a row of "not run yet", a run gate with true condition notes, and a run gate with a shorter true note are green. A run gate whose conditions still say "has not been run", or say nothing, or name the wrong version, and a "not met" row with stale conditions, are red. Matching the old exact "not run |" row again turns "not run yet" red. The twelve F2.1 mutants were run again and are still red. Every file was restored, checked by SHA-256. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 parent 6f12a64 commit 4c8120d

1 file changed

Lines changed: 11 additions & 3 deletions

File tree

‎tests/docsTruth.test.ts‎

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,8 @@ test('ULTRA-ROADMAP says how the Track U gate stands for every release granted a
195195
// Otherwise the release reads as a breach of the gate.
196196
const doc = read('ULTRA-ROADMAP.md');
197197
const gateRow = lineStarting(read('docs', 'superpowers', 'plans', '2026-09-30-trackU-owner-issues.md'), '| Track U gate |');
198-
const notRun = /^\| Track U gate \| not run \|/.test(gateRow);
198+
// "not run", "not run yet", "not run (…)": the gate has not been run. Anything else ("run 8 Oct: …", "not met …") records a run.
199+
const notRun = /^\| Track U gate \| not run\b/.test(gateRow);
199200
const granted = [...doc.matchAll(/^ {2}- \*\*Changed for (\d+\.\d+\.\d+) \([^)]+\):\*\*/gm)].map((m) => m[1]);
200201
assert.ok(granted.length >= 1, 'the Release bullet records a release granted ahead of the phases');
201202

@@ -223,8 +224,15 @@ test('ULTRA-ROADMAP says how the Track U gate stands for every release granted a
223224
assert.ok(exception, `the exceptions you approved list ${v}`);
224225
assert.match(exception, /the phases, not the Track U gate/, `the exception for ${v} does not cover the gate`);
225226
for (const [where, text] of conditions) {
226-
const stands = notRun ? 'the gate has not been run, and' : '(?!the gate has not been run)[^)]*';
227-
assert.match(text, new RegExp(`\\(${ver}: ${stands} whether ${ver} waits for it is your decision; see the Release bullet at the top\\)`), `${where} says how the gate stands for ${v}`);
227+
if (notRun) {
228+
assert.match(text, new RegExp(`\\(${ver}: the gate has not been run, and whether ${ver} waits for it is your decision; see the Release bullet at the top\\)`), `${where} says how the gate stands for ${v}`);
229+
continue;
230+
}
231+
// The plan records the gate run: the condition says how it stands for
232+
// this release in its own words (what the run recorded), and no longer
233+
// that it has not been run.
234+
assert.match(text, new RegExp(`\\(${ver}: [^)]*\\bgate\\b[^)]*\\)`), `${where} says how the gate stands for ${v}`);
235+
assert.doesNotMatch(text, new RegExp(`\\(${ver}: [^)]*\\bhas not been run\\b`), `the plan's row records the gate run, so ${where} does not say it was not (${gateRow.slice(0, 60)})`);
228236
}
229237
}
230238
});

0 commit comments

Comments
 (0)