Skip to content

fix(ci): carry the no_tests_matched escape through every coverage/results upload step#8173

Merged
JSONbored merged 1 commit into
mainfrom
fix/codecov-policy-no-tests-matched
Jul 23, 2026
Merged

fix(ci): carry the no_tests_matched escape through every coverage/results upload step#8173
JSONbored merged 1 commit into
mainfrom
fix/codecov-policy-no-tests-matched

Conversation

@JSONbored

Copy link
Copy Markdown
Owner

Main is currently red on test/unit/codecov-policy.test.ts for 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: true on 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: actionlint green, all 8 policy tests green. Merging this un-reds the suite for every open branch.

…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.
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@JSONbored JSONbored self-assigned this Jul 23, 2026
@JSONbored
JSONbored merged commit 83c8d70 into main Jul 23, 2026
4 checks passed
@JSONbored
JSONbored deleted the fix/codecov-policy-no-tests-matched branch July 23, 2026 08:23
@loopover-orb loopover-orb Bot added the gittensor:bug Gittensor-scored bug fix — scores a 0.05x multiplier. label Jul 23, 2026
@codecov

codecov Bot commented Jul 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.06%. Comparing base (e9adc75) to head (c832e97).
⚠️ Report is 5 commits behind head on main.
✅ All tests successful. No failed tests found.

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     
Flag Coverage Δ
control-plane 99.84% <ø> (ø)
rees 88.56% <ø> (ø)
shard-1 57.21% <ø> (-0.01%) ⬇️
shard-2 52.55% <ø> (ø)
shard-3 53.72% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.
see 228 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gittensor:bug Gittensor-scored bug fix — scores a 0.05x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant