test(formats): invert the primitives tripwire to pin the fix (#38, option A) #40
Reference in New Issue
Block a user
Delete Branch "fix/38-invert-primitives-tripwire"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Implements #38, option A. Keeps
include_primitivesoff by default and turns the tripwireinto a guard that the fix holds. Test-only: no library code changes.
The change
the_derived_order_puts_primitives_last_and_that_wipes_screensno_build_is_wiped_with_primitives_onwiped_on > 0— the bug still reproducesassert_eq!(wiped_on, 0)— the fix still holdsinclude_primitives: falseThe old name asserted the bug, so it's renamed, as #38 specifies. The old name survives in the
doc comment for anyone searching from the issue. The new failure message says what a failure
now means (
forced_backdropregressed), and says not to "fix" it by turning primitives offin the test. Nothing else in the repo cited the old name.
It's the only end-to-end check of the rule: the four tests in
ui_forced_backdrop_disc.rspinits mechanics, and none of them composes with primitives on.
Verified with the corpus present — including that it can fail
forced_backdropdisabled (return false;)📌 The control's 36 is exactly the "36 builds … wiped by our own sort" that
53f8345andui-forced-backdrop.mdreport. The guard reproduces the fix's own documented number on itsown, so it measures exactly what was repaired rather than a nearby proxy.
The control was a one-line edit, reverted afterwards;
git diffshowed only this test filebefore committing.
cargo fmt --all --checkclean; no clippy hits in the file.⚠️ CI will be green here for the same reason it was green on
mainThe runner has no corpus, so this suite self-skips and reports
okeither way. The tableabove is the evidence for this PR, and only a machine with the disc can produce it. On
main@e0187d6the disc suite currently reads 45 suites / 376 passed / 1 failed — thisPR should bring that to 377 / 0.
⚠️ Merging closes #38 — one item on it is not filed anywhere else
#38 also carries the Pi's separate note about the loop briefs: the tripwire stayed red for 15
days because an agent reported a subset of test files as green. That note isn't an issue of
its own yet. File it separately before or when this merges, or it closes with #38.
Closes #38
🤖 Generated with Claude Code