ci: exclude additional boilerplate from code coverage#3382
Conversation
Add the following to .codecov.yml ignore list: - rs-dapi core_service.rs (gRPC handler requiring live Core node) - rs-drive-proof-verifier types.rs and unproved.rs (response type boilerplate) - rs-sdk mock infrastructure (test-only scaffolding) - rs-dpp document_type accessors (getter/setter trait impls) - rs-dpp core_types (chain type wrappers and deserialization boilerplate) These files contain untestable infrastructure, pure accessor boilerplate, or test-only scaffolding that skews coverage metrics without reflecting meaningful gaps in test quality. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. 📝 WalkthroughWalkthroughAdded ignore patterns to Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.codecov.yml (1)
66-69: Consider narrowing broad excludes to reduce future coverage blind spots.
packages/rs-dpp/src/data_contract/document_type/accessors/**and especiallypackages/rs-dpp/src/core_types/**are broad. If new business logic lands there later, it will be silently excluded from coverage. Consider either file-level patterns or a periodic audit note to keep this safe over time.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In @.codecov.yml around lines 66 - 69, The coverage excludes for "packages/rs-dpp/src/data_contract/document_type/accessors/**" and "packages/rs-dpp/src/core_types/**" are too broad and may hide future business logic; replace these glob-wide exclusions with tighter file-level patterns (e.g., list specific generated files or exact filenames under document_type/accessors and only exclude known generated or wrapper files under core_types) or add a TODO/audit comment in .codecov.yml indicating these globs must be reviewed periodically; update the exclude entries accordingly so only truly non-testable/generated code is omitted and new business logic will remain covered.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In @.codecov.yml:
- Around line 66-69: The coverage excludes for
"packages/rs-dpp/src/data_contract/document_type/accessors/**" and
"packages/rs-dpp/src/core_types/**" are too broad and may hide future business
logic; replace these glob-wide exclusions with tighter file-level patterns
(e.g., list specific generated files or exact filenames under
document_type/accessors and only exclude known generated or wrapper files under
core_types) or add a TODO/audit comment in .codecov.yml indicating these globs
must be reviewed periodically; update the exclude entries accordingly so only
truly non-testable/generated code is omitted and new business logic will remain
covered.
Issue being fixed or feature implemented
Code coverage metrics are skewed by untestable infrastructure, pure accessor boilerplate, and test-only scaffolding that cannot or should not carry meaningful test coverage.
What was done?
Added the following paths to the
.codecov.ymlignore list:packages/rs-dapi/src/services/core_service.rs— gRPC service handler that wraps Core RPC calls; requires a running Dash Core node, so it cannot be unit-tested (0% coverage, 265 lines)packages/rs-drive-proof-verifier/src/types.rs— Response type constructors and conversion boilerplate for proof verification results (13.8% coverage, 193 lines)packages/rs-drive-proof-verifier/src/unproved.rs— Unproved response handling boilerplate (0% coverage, 141 lines)packages/rs-sdk/src/mock/**— Mock infrastructure for SDK testing, not production logicpackages/rs-dpp/src/data_contract/document_type/accessors/**— Pure getter/setter trait implementations, same category as the already-excluded state transition accessors (42.6% coverage, 296 lines)packages/rs-dpp/src/core_types/**— Core chain type wrappers (masternode entries etc.) that are mostly deserialization boilerplate (42.6% coverage, 255 lines)How Has This Been Tested?
This is a configuration-only change to
.codecov.yml. The excluded paths were verified to exist in the repository and to match the rationale (boilerplate, untestable infrastructure, or test-only code).Breaking Changes
None. This only affects coverage reporting, not any build or runtime behavior.
Checklist:
Summary by CodeRabbit