fix(ci): carry the no_tests_matched escape through every coverage/results upload step#8173
Merged
Merged
Conversation
…ults upload step #8167 taught the verify step that a scoped selection matching zero test files writes no report and is not a failure -- but left every upload step below it unguarded, so the trusted/fork coverage uploads (fail_ci_if_error: true) would still turn that non-event red on the missing lcov, and the junit uploads would noisily fail on a missing xml. It also left codecov-policy.test.ts pinning the old verify condition, which broke that suite on main for every branch. Adds the same steps.coverage.outputs.no_tests_matched guard to all five upload steps and re-pins the policy test to the completed invariant: the escape hatch exists exactly once, and every upload below the verify step carries it.
Merged
25 tasks
Contributor
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8173 +/- ##
===========================================
+ Coverage 81.49% 92.06% +10.57%
===========================================
Files 768 768
Lines 77827 77828 +1
Branches 23514 23513 -1
===========================================
+ Hits 63423 71653 +8230
+ Misses 11749 5062 -6687
+ Partials 2655 1113 -1542
Flags with carried forward coverage won't be shown. Click here to find out more. |
This was referenced Jul 23, 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.
Main is currently red on
test/unit/codecov-policy.test.tsfor every branch: #8167 changed the verify step's condition without updating the policy test. Investigating exposed the real gap — the escape hatch stopped at the verify step, so a legitimately zero-test scoped run would still fail at the coverage uploads (fail_ci_if_error: trueon a missing lcov), defeating #8167's purpose.This PR completes the escape (all five upload steps now carry
steps.coverage.outputs.no_tests_matched != 'true') and re-pins the policy test to the completed invariant. Verified:actionlintgreen, all 8 policy tests green. Merging this un-reds the suite for every open branch.