Repository navigation
Closed
Labels
area: modulesFirst-party content modules and the module seam.priority: p1Scheduled into the current or next milestone.type: testCoverage, harness or proof work with no behaviour change.
Milestone
Description
Context
This is one shard of the test-health push in #3855. Shard e3855-module-diagrams-01 covers the 17 Bun unit test files under packages/module-diagrams/tests/. They were audited through all eight lenses in 9 clusters, in run th-20261110203030-1866df, on branch test-health/e3855-module-diagrams-01 (cut from epic/3855-test-health).
Fixed findings, each with a killed mutation receipt:
packages/module-diagrams/tests/positional.test.ts, conditional-assertion, four cases. Each assertion ran only inside a loop over a collection that could be empty:- loop/flywheel clearance: the label masks and ring arcs it samples are now pinned (2 masks for loop, 5 arcs). Mutant killed: spoke masks repainted as nodes (
packages/module-diagrams/src/positional-layout.ts:78). - generated scenes: the ring radius, sweep and station-edge checks ran only for ids starting with
ring-. Five ring paths are now pinned for loop and flywheel. Mutant killed: ring paths renamed (positional-layout.ts:61). - Venn: the intersection containment loop now pins the region count to the authored intersections. Mutant killed: intersection region renamed (
positional-layout.ts:107). - pyramid/funnel: the width, apex and text-inside checks sat in
polygons.forEach. Four trapezoids are now pinned. Mutant killed: polygon shape kind changed (positional-layout.ts:19).
- loop/flywheel clearance: the label masks and ring arcs it samples are now pinned (2 masks for loop, 5 arcs). Mutant killed: spoke masks repainted as nodes (
packages/module-diagrams/tests/spec.test.ts, empty-by-construction. Every off-grid input was odd (189, 149), so a grid check weakened to mod 2 still passed. An even off-grid x of 190 is now refused by its exact finding. Mutant killed:% 4changed to% 2(packages/module-diagrams/src/check.ts:121).packages/module-diagrams/tests/skin.test.ts, empty-by-construction. Same gap in the authored-narrow grid case (x = 41 only). An x = 42 case is added. Mutant killed:% 4changed to% 2(packages/module-diagrams/src/layout.ts:37).packages/module-diagrams/tests/export.test.ts, opaque-failure. Asome(...)boolean now compares the audit issue category and path, so a failure prints the issues.
Scope
Test code under packages/module-diagrams/tests/ only.
Out of scope
Product code, timeouts, shards and selection, and test files outside the shard.
Acceptance criteria
- The batch gate (
bun scripts/test-health.ts batch verify --base origin/epic/3855-test-health) passes, with no test removed (50 tests before and after). - Each fixed finding carries a killed mutation receipt in the run directory.
Verification
bun scripts/test-health.ts batch verify and bun run check:pr --base origin/epic/3855-test-health on the batch head.
Contract impact
None.
Metadata
Metadata
Assignees
Labels
area: modulesFirst-party content modules and the module seam.priority: p1Scheduled into the current or next milestone.type: testCoverage, harness or proof work with no behaviour change.
Activity
schlessera commentedon Nov 11, 2026
Delivered by #3913, which merged into
epic/3855-test-healthas25d946858(the push in #3855). It landed in the combined merge without proof of its own; the gate, typecheck andcheck:prpassed on the combined branch. The epic's two exhaustive runs ondc2439551, 42996974186 and 42997012467, then passed. GitHub does not applyClosesfor a pull request into a non-default branch, so I'm closing this by hand. The change reachesmainwith the epic's single landing pull request.