Report test results & coverage in the CI run summary - #96
Merged
Merged
Conversation
The suite already ran with coverage and uploaded both reports as artifacts, so the numbers were only visible by downloading an artifact or scrolling the job log. This posts them to the run summary instead, in the same shape as the jobs in vision-download and webhook-verifier-nodejs. The job runs once on 26.x rather than across the 22/24/26 matrix, so the run gets one summary rather than three, and `Lint & test` is untouched. Artifacts still come from that job, per Node version, so this one only writes the summary. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
jstayton
added a commit
to TRUEPIC/webhook-verifier-nodejs
that referenced
this pull request
Aug 27, 2026
The coverage job ran the tests and reported only coverage, so the test
results stayed in the job log. Node prints its own summary block right
before the coverage report, so surfacing it costs one more `grep`.
Reporting now happens in its own step. The default shell is `bash -e`, so
`set -o pipefail` made a failing suite abort the step before it wrote the
summary — the run lost both the results and the coverage report at the
one moment they were most worth reading. Node emits both even when tests
fail, so `if: ${{ !cancelled() }}` is enough to keep them.
This matches the shape of the job in queryql:
TRUEPIC/queryql#96
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
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.
npm test -- --ci --coveragealready ran in CI and both reports were alreadyuploaded as artifacts, so the numbers were only visible by downloading an
artifact or scrolling the job log. This posts them to the run summary, in the
same shape as the jobs in vision-download and
TRUEPIC/webhook-verifier-nodejs#46.
No thresholds. Reported, not enforced.
Matching webhook-verifier-nodejs#46: a separate job, run once on 26.x rather
than across the 22/24/26 matrix so the run gets one summary rather than three,
and
set -o pipefailbecausenpm test | teereturns tee's status, notJest's — without it the job reports green on a broken suite.
Lint & testisuntouched, and the per-Node-version artifacts still come from there, so this
job only writes the summary.
One deliberate difference from #46, which combines the run and the report into
a single step: because the default shell is
bash -e, a failing suite abortsthat step before the summary block runs, so no summary is written. Splitting
the report into its own step with
if: ${{ !cancelled() }}means it is stillwritten when tests fail — which is when the test results are the most worth
reading. Verified both ways. #46 has the same gap and may want the same split,
since its
specreporter output is also only in the job log.Rendered summary:
🤖 Generated with Claude Code