Repository navigation
ci: add coverage targets - #88
Merged
Merged
Conversation
Fail ./mvnw verify if the unit and integration tests together cover less than 60% of the lines or 45% of the branches (JaCoCo merge and check; now 62% and 47%), and set Codecov targets: no drop of the project's coverage, full coverage of the changes of a pull request. Closes #82 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reviewer's GuideConfigurationMerge unit- and integration-test JaCoCo data and enforce local coverage floors, while configuring Codecov to guard project coverage and require full coverage of changed lines.
DocumentationDocument the local JaCoCo coverage floors and the Codecov pull-request checks for contributors.
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## dev #88 +/- ##
=======================================
Coverage 56.39% 56.39%
=======================================
Files 66 66
Lines 2167 2167
Branches 236 236
=======================================
Hits 1222 1222
Misses 804 804
Partials 141 141 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
uniqueg
marked this pull request as ready for review
November 7, 2026 08:08
There was a problem hiding this comment.
Hey - I've reviewed your changes and they look great!
Linked issues
#82 ci: add coverage targets · 4 of 4 met
| # | Requirement | Status | Notes |
|---|---|---|---|
| 1 | Set a Codecov project target so coverage does not drop. | ✅ Met | codecov.yml sets the project target to auto with a 0.5% threshold. |
| 2 | Set a Codecov patch target for the changed lines of each pull request. | ✅ Met | codecov.yml sets the patch target to 100%. |
| 3 | Check merged unit and integration coverage in ./mvnw verify, failing below the current coverage floor. |
✅ Met | pom.xml merges jacoco.exec and jacoco-it.exec, then checks for at least 60% line coverage and 45% branch coverage during verify. |
| 4 | Document how coverage is checked for developers. | ✅ Met | docs/development.md describes the JaCoCo floors and Codecov targets. |
Sourcery assessment
Approved.
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 targets, as foca, cloud-registry and proTES have them:
pom.xml: JaCoCo merges the unit and integration test data (jacoco-merged.exec) andcheckfails./mvnw verify, and so theTestjob and the gateCI passed, below 60% of the lines or 45% of the branches. The tests cover 62% and 47% now; raise the floors as coverage grows.codecov.yml: the project's coverage must not drop (threshold 0.5 percentage points), and the changed lines of each pull request must be covered completely (100%, as in the other repositories). The Codecov statuses are not required checks.docs/development.mddescribes both.Closes #82 (part of #65)
Verification
./mvnw -B clean verify(ineclipse-temurin:8-jdk, Java 8 as CI) failed with "lines covered ratio is 0.62, but expected minimum is 0.99" and "branches covered ratio is 0.47"; with the floors of this PR it passes ("All coverage checks have been met", 111 unit and 53 integration tests).-Dmaven.test.skip=true package) doesn't reachverify, so it is unaffected.CI passed, Test with the coverage check, Smoke test, Scan image, Docs, Lint, CodeQL, Codecov).Lane
Light lane: build and CI configuration only (a coverage check with its floor), no secrets, permissions or release workflow; I reviewed the diff myself.
Declined review findings
None.
Open questions
None.
🤖 Generated with Claude Code
Summary by Sourcery
Add coverage quality gates for combined test results and pull-request changes.
Enhancements:
Documentation: