Repository navigation
test: name the run in e2e coverage tooling-error artifacts - #1070
Merged
Merged
Conversation
main() in tests/tools/e2e-coverage-report.mjs built its failure report from error.runId / error.runStatus, which only CoverageReportError carries. Every throw raised after the manifest is read and validated is a plain Error, so the published artifact header read E2E coverage: tooling-error (run null; status unknown) even for a run sealed passed. CI cats that text straight into the step summary, so a reader of a red End-to-end coverage job could not tell whether the Playwright run failed or only the reporting step broke. Fall back to the manifest, which readCoverageRun can re-read from --input. An unreadable or absent manifest still yields null, exactly as before. Closes #1069 Signed-off-by: quality <quality@hive.kubestellar.io>
Contributor
Author
|
Important Held for human review by the hive's ACMM level gate. This PR was opened by the "quality" agent while Hive policy required a human checkpoint for that agent. Non-outreach agents are held at ACMM L3–L5; the Hive will automatically remove the |
This was referenced Oct 5, 2026
…n-identity Signed-off-by: quality <quality@hive.kubestellar.io> # Conflicts: # tests/e2e-coverage-report.test.mjs
github-merge-queue
Bot
removed this pull request from the merge queue due to failed status checks
Oct 5, 2026
This was referenced Oct 5, 2026
This was referenced Oct 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Test Improvement
main()intests/tools/e2e-coverage-report.mjsbuilt its failure artifact fromerror.runId/error.runStatus. OnlyCoverageReportErrorcarries those, andonly the three run-status/capture guards near the top of
collectE2ECoverageraise it. Every throw after the manifest has been read and validated — the
.tmpguard, the artifact-kind and run-id guards, everyconvertScriptsource-mapfailure, and
No src/** coverage was attributable— is a plainError, so thepublished header read:
even when
manifest.jsonon disk said"runId": "run-1", "status": "passed"..github/workflows/ci.ymlcatscoverage/e2e/report.txtstraight into$GITHUB_STEP_SUMMARY, and that line is the whole diagnostic. It could notdistinguish "the Playwright run failed" from "only the reporting step broke" —
two failures with opposite remedies.
This re-reads the manifest in the catch.
readCoverageRunwas already imported;.catch(() => null)leaves an unreadable or absent manifest behaving exactly asit does today.
Tests
Two cases appended to
tests/e2e-coverage-report.test.mjs:a tooling-error artifact still names the run the manifest records— seals arun
passed, trips theNo src/**path, and asserts the JSON carriesrunId: 'run-1'/runStatus: 'passed'and the text header readsE2E coverage: tooling-error (run run-1; status passed). Verifiednon-vacuous: reverting only the
.mjschange fails this test and no other.a tooling-error artifact reports no run when the manifest is unreadable—pins the unchanged
null/nullbehaviour.Scope note
Issue #1069's second completion box — a run sealed
failed/cancelledreportedwith that status rather than
tooling-error— is not reachable and isdeliberately not implemented.
collectE2ECoveragerejects every non-passedrun with a
CoverageReportErrorbefore any plain-Errorsite runs, so themanifest fallback can only ever observe
passed, and the existing ternary onerror.runStatusalready handles the sealed-failedcase correctly (covered bymain labels failed runs as failed and exits nonzero). Adding the branch wouldbe dead code. I have said the same on the issue; nothing else is left for it to
track.
Verification
node --test tests/e2e-coverage-report.test.mjs— 37 passed, 0 failed.npm run test:unit:coverage:check— exit 0 (--check-source 100,--check-source-regions 99).npx prettier --checkon both changed files — exit 0.Local revision
900592b, node v26.10.0,TZ=UTC.Coordination
Touches only
main()(tests/tools/e2e-coverage-report.mjs) and appends totests/e2e-coverage-report.test.mjs.convertScriptand the script-root resolutioninside
collectE2ECoverage; it touches nothrowsite and notmain().getRegionCoverageand the region union; it does not touchmain().Both append to
tests/e2e-coverage-report.test.mjsat the end, so a trivialappend-order rebase is possible there; no logic overlaps.
Related Issue
Closes #1069
— hive: agent=quality backend=copilot model=claude-opus-5 copilot=1.0.88