Public: anyone can read this; the crew can change it.
A test reproduces the failing-test-name hold finding: a hold by substring fails on main #15134
Check · Review · Land · Live done — Landed and live in production.
A failing test no longer holds an issue that names a longer, hyphenated test: foo does not hold foo-bar, and keeps its chart does not hold keeps its chart-axis. A new test file reproduces the finding from #14991, and a one-line fix closes a gap the test found. The gap.
shipped production is serving it deploy be80413
A failing test no longer holds an issue that names a longer, hyphenated test: foo does not hold foo-bar, and keeps its chart does not hold keeps its chart-axis. A new test file reproduces the finding from #14991, and a one-line fix closes a gap the test found.
The gap. The fix in #15002 stops foo from holding foo-bar only because foo is under the 4-character minimum (MIN_NAME). The whole-name check in quotes (src/crew/red_fix.ts) treated a hyphen as the end of a name. So a name long enough to count still held an issue that named it with a hyphenated suffix. A hyphen now counts as part of a name, so foo-bar reads as one name. A hyphen with spaces around it (keeps its chart - and …) still counts as the end of a name.
test/red-fix-whole-name.test.ts has three cases:
- An issue naming
foo-baris not held by a failing testfoo. This fails if the check goes back to a plain substring match (text.includes(name)). - A name past the minimum is not held inside a hyphenated one. This fails on today's main without the change to
red_fix.ts. - An issue that names the failing test whole is held, whether in backticks, in quotes, at the end of a line, or before a spaced dash.
I swapped in both versions locally to confirm each failure, then restored the code.
The new file is in the gate without any edit: scripts/gate.ts runs every test file that is not in EXCLUDED. The only other caller of this check is held.ts:288. Its test in test/crew-held.test.ts and the earlier cases in test/red-main.test.ts pass unchanged.
Not done: the names are still not filtered where they are recorded (src/checks/red_main.ts), as in #15002. The keep_plan and estimate tools the issue mentions are not available in this run, so no plan was kept on the issue.
Checks: bun scripts/gate.ts --fix and bun x tsc --noEmit are clean. scripts/fast.ts picked 285 files (about 24 minutes), so I ran the 9 that cover this check: red-fix-whole-name, red-main, crew-held, boards-held, holds, shared-red, test-honesty, unused-exports and check-allow-lists. All 122 tests pass. The full suite is left to the forge's check.
To try it: bun test test/red-fix-whole-name.test.ts test/red-main.test.ts
Closes #15131
🤖 Generated with Claude Code
Clean, small, single-purpose. A hyphen now continues a name in quotes(), so a failing test no longer holds an issue naming a longer hyphenated one. Tests cover the substring case, the past-MIN_NAME hyphen case, and whole-name holds. No security surface, no dependency, no README change. The new file is picked up by the gate with no list edit.
A failing test no longer holds an issue that names a longer, hyphenated test:
foodoes not holdfoo-bar, andkeeps its chartdoes not holdkeeps its chart-axis. A new test file reproduces the finding from #14991, and a one-line fix closes a gap the test found.The gap. The fix in #15002 stops
foofrom holdingfoo-baronly becausefoois under the 4-character minimum (MIN_NAME). The whole-name check inquotes(src/crew/red_fix.ts) treated a hyphen as the end of a name. So a name long enough to count still held an issue that named it with a hyphenated suffix. A hyphen now counts as part of a name, sofoo-barreads as one name. A hyphen with spaces around it (keeps its chart - and …) still counts as the end of a name.test/red-fix-whole-name.test.tshas three cases:foo-baris not held by a failing testfoo. This fails if the check goes back to a plain substring match (text.includes(name)).red_fix.ts.I swapped in both versions locally to confirm each failure, then restored the code.
The new file is in the gate without any edit:
scripts/gate.tsruns every test file that is not inEXCLUDED. The only other caller of this check isheld.ts:288. Its test intest/crew-held.test.tsand the earlier cases intest/red-main.test.tspass unchanged.Not done: the names are still not filtered where they are recorded (
src/checks/red_main.ts), as in #15002. Thekeep_planandestimatetools the issue mentions are not available in this run, so no plan was kept on the issue.Checks:
bun scripts/gate.ts --fixandbun x tsc --noEmitare clean.scripts/fast.tspicked 285 files (about 24 minutes), so I ran the 9 that cover this check: red-fix-whole-name, red-main, crew-held, boards-held, holds, shared-red, test-honesty, unused-exports and check-allow-lists. All 122 tests pass. The full suite is left to the forge's check.To try it:
bun test test/red-fix-whole-name.test.ts test/red-main.test.tsCloses #15131
🤖 Generated with Claude Code
Closes #15131