non-production: set up codecov in this repo#151
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Sets up Codecov coverage reporting for this Ruby repo by ensuring coverage collection starts before the library is loaded and by allowing the CI workflow to pass the Codecov token into the shared test-matrix workflow.
Changes:
- Load SimpleCov configuration via
spec/simplecov_helper.rbas the first line ofspec/spec_helper.rbso coverage starts beforerequire 'process_settings'. - Emit LCOV (
coverage/lcov.info) on GitHub Actions viasimplecov-lcov, while keeping HTML coverage locally. - Update the pipeline workflow to pass secrets into the reusable workflow call for Codecov upload.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| spec/spec_helper.rb | Requires the new SimpleCov helper before loading the gem to avoid under-reporting coverage. |
| spec/simplecov_helper.rb | Centralizes SimpleCov config and switches formatters based on CI vs local runs. |
| .github/workflows/pipeline.yml | Adjusts reusable workflow invocation to make Codecov token available to the upload step. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Welcome to Codecov 🎉Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests. Thanks for integrating Codecov - We've got you covered ☂️ |
- Pass secrets: inherit to the shared ruby-test-matrix workflow so CODECOV_TOKEN reaches the Codecov upload step - Move the inline SimpleCov config into spec/simplecov_helper.rb, loaded first in spec_helper.rb so coverage starts before the gem code loads - Emit coverage/lcov.info via simplecov-lcov on CI, HTML report locally
dcaddell
approved these changes
Jul 15, 2026
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.
non-production: set up codecov in this repo
Summary of Changes
secrets: inheritto the shared ruby-test-matrix workflow soCODECOV_TOKENreaches the Codecov upload step.spec/spec_helper.rbintospec/simplecov_helper.rb, required as the first line ofspec_helper.rbso coverage starts before the gem's code is loaded (previously SimpleCov started afterrequire 'process_settings', under-reporting coverage).GITHUB_ACTIONS), emits lcov tocoverage/lcov.infovia simplecov-lcov; locally uses the HTML formatter.Measured local coverage: 94.82% line coverage (227 examples, 0 failures).
No
codecov.ymladded since coverage is above 80%.