Summary
gate-26 decides "is this page component covered?" by looking for the component's file stem in the text of tests/e2e/**. A well-written Playwright test navigates by URL route and asserts on accessible names — it has no reason to contain the component's filename. So:
- a page that is driven by a green, executing e2e test is reported uncovered, and
- a page that is merely named in a comment is reported covered.
Measured on openregister: 11 of its 21 findings are false, and 6 of its 16 passes are prose-only. The signal is close to inverted.
Measured
Canonical package @main (3c8da4c), pristine worktree of openregister@origin/development = fdb0d6ca8.
(a) Prose-only passes. Re-running the gate's own is_covered() against a comment-stripped corpus:
page components discovered: 37
UNCOVERED (gate's own verdict): 21
COVERED ONLY BY A COMMENT: 6
The six, with the line that silences each:
src/views/avg/AvgIndex.vue
tests/e2e/workflows/dsar-cases.spec.ts:6: * Cases tab added to the AVG view (src/views/avg/AvgIndex.vue): the case
src/views/integration/IntegrationsView.vue
tests/e2e/leaf-screenshots.spec.ts:5: * IntegrationsView (/integrations/:register/:schema/:objectId), then
src/views/organisation/OrganisationsIndex.vue
tests/e2e/spec-coverage/admin-settings-pages.spec.ts:108: // (OrganisationsIndex.vue), so on a stock instance with exactly one
src/views/Endpoint/EndpointsIndex.vue
tests/e2e/spec-coverage/admin-settings-pages.spec.ts:170: // NOTE: EndpointsIndex renders no page <h1>; assert the primary action.
src/views/files/FilesIndex.vue
tests/e2e/spec-coverage/feature-pages.spec.ts:103: // FilesIndex exposes a "Toggle search sidebar" action (not a
src/views/object/ObjectsIndex.vue
tests/e2e/integration-mount.spec.ts:117: * Open the object detail page (ObjectDetails.vue, served by ObjectsIndex)
Note the first two are silenced by comments in files no Playwright project runs — doubly fictional.
(b) The false positives. Mapping the 21 flagged pages through src/manifest.json against the routes the five CI-executed specs actually navigate to:
pages whose route a CI-RUN spec already navigates to: 11 of 21
MyAccount(/mijn-account) ApplicationsIndex(/applications)
ConfigurationsIndex(/configurations) SearchTrailIndex(/search-trails)
ReportsIndex(/reports) FeaturesRoadmapIndex(/features-roadmap)
SchemasIndex(/schemas) SourcesIndex(/sources)
TemplatesIndex(/templates) WebhooksIndex(/webhooks)
WebhookLogsIndex(/webhooks/logs)
These pages are driven, asserted and green in CI today — I ran the suite on a dedicated NC 34 rig: 44 passed, 0 failed.
Mechanism
check_visual_coverage.py:
def is_covered(page, visual_corpus, e2e_corpus):
stem = Path(page["path"]).stem
pid = page["id"]
needles = {stem, pid}
...
for needle in needles:
if needle and re.search(rf"\b{re.escape(needle)}\b", e2e_corpus):
return True
_e2e_corpus() concatenates raw file text, comments included. So the needle is a filename, and the corpus is prose + code undifferentiated.
Both offered remedies are wrong
The finding message reads:
… missing visual-regression baseline (tests/e2e/visual/**) / e2e test / @visual exclude
tests/e2e/visual/** — in openregister (and, from the fleet board, elsewhere) that directory is outside the testMatch the CI config uses, so a baseline placed there is never executed. The gate would go green over a file nothing runs.
- "e2e test" — cannot see a URL-driven test, which is what a good one looks like.
@visual exclude — a waiver on a page that is covered.
That leaves exactly one cheap satisfying action: write the component name into a comment. Six components in this repo are green by precisely that route. A gate whose cheapest satisfying action is prose will be satisfied by prose — cf. #358.
Proposed fix
Two halves, and they move the number in opposite directions, which is why they should land together:
- Resolve
component → route from src/manifest.json / the registry, and count a test that navigates to that route (goto with the route literal, or a route constant) as coverage. Removes the 11 false positives.
- Strip comments from the e2e corpus before needle matching. Reddens the 6 prose-only passes.
Net on openregister: 21 → 16.
⚠️ Not merging. Half of this reddens repos, same hold as #347 / #349 / #356 / #361, and #359's acceptance suite should land first so the change arrives with a fixture. Filing with the measurement so it can be sequenced.
There is a precedent in this same file for a fix landing with its own regression note: check_visual_coverage.py:472 records the exit-status-as-count bug and how it was fixed.
Provenance
Found while closing gate-26 on openregister. I was about to write baselines for 11 pages that already have passing behavioural tests.
Summary
gate-26 decides "is this page component covered?" by looking for the component's file stem in the text of
tests/e2e/**. A well-written Playwright test navigates by URL route and asserts on accessible names — it has no reason to contain the component's filename. So:Measured on openregister: 11 of its 21 findings are false, and 6 of its 16 passes are prose-only. The signal is close to inverted.
Measured
Canonical package
@main(3c8da4c), pristine worktree ofopenregister@origin/development=fdb0d6ca8.(a) Prose-only passes. Re-running the gate's own
is_covered()against a comment-stripped corpus:The six, with the line that silences each:
Note the first two are silenced by comments in files no Playwright project runs — doubly fictional.
(b) The false positives. Mapping the 21 flagged pages through
src/manifest.jsonagainst the routes the five CI-executed specs actually navigate to:These pages are driven, asserted and green in CI today — I ran the suite on a dedicated NC 34 rig: 44 passed, 0 failed.
Mechanism
check_visual_coverage.py:_e2e_corpus()concatenates raw file text, comments included. So the needle is a filename, and the corpus is prose + code undifferentiated.Both offered remedies are wrong
The finding message reads:
tests/e2e/visual/**— in openregister (and, from the fleet board, elsewhere) that directory is outside thetestMatchthe CI config uses, so a baseline placed there is never executed. The gate would go green over a file nothing runs.@visual exclude— a waiver on a page that is covered.That leaves exactly one cheap satisfying action: write the component name into a comment. Six components in this repo are green by precisely that route. A gate whose cheapest satisfying action is prose will be satisfied by prose — cf.
#358.Proposed fix
Two halves, and they move the number in opposite directions, which is why they should land together:
component→routefromsrc/manifest.json/ the registry, and count a test that navigates to that route (gotowith the route literal, or arouteconstant) as coverage. Removes the 11 false positives.Net on openregister: 21 → 16.
#347/#349/#356/#361, and#359's acceptance suite should land first so the change arrives with a fixture. Filing with the measurement so it can be sequenced.There is a precedent in this same file for a fix landing with its own regression note:
check_visual_coverage.py:472records the exit-status-as-count bug and how it was fixed.Provenance
Found while closing gate-26 on openregister. I was about to write baselines for 11 pages that already have passing behavioural tests.