ci: measure coverage on the unit suite too - #23
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
codecov/patchfails on any pull request that touches code outside the Redis repository, and it is not the pull request's fault.Coverage is collected in one place: the integration job runs
pytest -m integration --cov=idempotency_kitand uploads that report. The unit matrix runspytest -m unitwith no coverage at all. So everything exercised only by unit tests reads as uncovered to Codecov, and a diff made mostly of unit-covered code arrives as a red patch status. The unit suite on its own reaches 95.66% of the package, none of which Codecov has ever seen.This adds
--covto the unit run and uploads it from the 3.13 matrix entry, withflags: uniton that upload andflags: integrationon the existing one so Codecov merges the two reports rather than letting the second overwrite the first. Nothing else changes: the integration job keeps its own--cov-fail-under=50, the unit job keeps the 85% floor thatpyproject.tomlalready sets, and the upload stayscontinue-on-errorso Codecov being down cannot fail a build.codecov/patchis not the required status check —All checks passedis — so this was never blocking a merge. It was making every pull request look broken.Found while fixing the findings in #22, which is where the red patch status shows. That branch turns green once it is updated on top of this.