Repository navigation
fix(coverage): resolve report paths against tracked files and reject non-Cobertura XML - #82
Merged
Merged
Conversation
…non-Cobertura XML Refs #80 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.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.
Summary
coverage.ymlnow maps every report path onto the repository's tracked files when it reads the reports, and rejects.xmlfiles incoverage-*artifacts that are not Cobertura. Refs #80.Changes
class@filenamewith<source>roots, lcovSF:) are canonicalized againstgit ls-files: exact path,<source>join, unique suffix of a tracked file, or the longest tracked suffix of a longer (container-prefixed) path. A suffix matching several tracked files is an error, even when the other file is not in the diff.<coverage>, fails the job with an explicit message.Fixed) updated.Test plan
bash .github/tests/coverage.sh: all cases pass, including the new ones (ambiguous suffix against tracked files, unique suffix with an uncovered patch, non-Cobertura XML, invalid XML) and the rewritten "longer report paths collapse onto the tracked file" case.actionlint -config-file .github/actionlint.yaml: clean.Screenshots
N/A
Risk
Intent
change, depth standard: localized behavior change in a shared reusable workflow. No caller ofcoverage.ymlexists yet, so no SemVer impact. Stricter behavior: non-Cobertura XML and ambiguous suffixes now fail instead of being ignored or silently misattributed.How to revert
Revert the squash commit.
Deployment notes
None. Target branch
main; released with the next v6 minor.🤖 Generated with Claude Code