Skip to content

ci: add PR coverage check workflow#6571

Closed
vividctrlalt wants to merge 9 commits intotronprotocol:developfrom
vividctrlalt:ci/coverage-check
Closed

ci: add PR coverage check workflow#6571
vividctrlalt wants to merge 9 commits intotronprotocol:developfrom
vividctrlalt:ci/coverage-check

Conversation

@vividctrlalt
Copy link
Contributor

Summary

  • Add a GitHub Actions workflow that compares JaCoCo code coverage between PR and base branch
  • Runs tests on both branches in parallel, aggregates per-module coverage, and posts a detailed comparison report as a PR comment
  • Configurable thresholds: fails the check if line coverage drops > 5%, warns if > 3%

Details

  • Parses JaCoCo XML reports at the report level (not method/class level) for accurate totals
  • Shows overall and per-module line/branch/instruction/method coverage with diff indicators
  • Updates existing PR comment on re-push instead of creating duplicates

Test plan

  • Workflow tested on fork PRs with various coverage scenarios
  • Verify report accuracy on real PRs against develop

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant