-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add codecov threshold #480
Conversation
to help with #477
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Personally, I want us to keep enforcing that master must have 100% code coverage.
I think the better approach would be to figure out how to write unit tests to cover the last few lines that are uncovered by unit tests currently (but are covered by our integration tests).
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dpa/merge-queue #480 +/- ##
================================================
Coverage 99.24% 99.24%
================================================
Files 12 12
Lines 395 395
================================================
Hits 392 392
Misses 3 3 ☔ View full report in Codecov by Sentry. |
I wonder if this configuration would work for that? |
Hmmm, so in the current state of this PR, it would allow the |
I don't really understand if this is about the branch we are merging from (/ running on), or the branch we are merging into. Either way I think this is incomplete though. If it is the branch we are running on, then we want the merge-queue branch to have the strict checks, not just main itself. If it is the branch we are merging into, then this won't help for PRs to main. |
I think maybe it does support regex actually. The docs are very incomplete but I found some old ones that suggested it does (and some older ones that suggested it didn't then) |
Ok, I had to fix the syntax a bit, but this now validates: curl -X POST --data-binary @codecov.yml https://codecov.io/validate
Valid!
{
"coverage": {
"status": {
"project": {
"main": {
"branches": [
"^main$",
"^gh-readonly-queue/main/.*"
],
"target": 100.0
},
"default": {
"target": 98.0
}
}
}
}
} |
How would we go about testing this to make sure it works the way we want? |
I think the easiest way is just by merging things. We can test the happy path by merging this and your PR down. Then we can test the failure path by deleting the integration tests and seeing if that merges down. If so we can revert back. |
…, and add some more unit tests (#477) * Run the integration tests on the `merge_group` event * Run the unit tests on the `merge_group` event * Delete `bors.toml` (the Bors config file) * CompatHelper's own Project.toml: add compat entries for our own test deps (#478) * Update .github/workflows/ci_integration.yml Co-authored-by: mattBrzezinski <matt.brzezinski@invenia.ca> * Update ci_integration.yml * Upload code coverage from the unit tests * Integration tests: immediately error if this is a PR build * Mark the integration tests as "skipped" on PR builds (#479) * Simplify the job name of the integration tests job This is necessary because the `${{ matrix... }}` interpolations are not evaluated for skipped jobs * Do some debugging * Revert the debugging commit * Don't use a matrix for the integration test job * Do some debugging * Revert the debugging commit * Delete some commented-out lines * Fix a comment * add codecov threshold (#480) * add codecov threshold to help with #477 * Update codecov.yml * fix indentation * Update codecov.yml * Update codecov.yml * Apply suggestions from code review Co-authored-by: Dilum Aluthge <dilum@aluthge.com> * Update codecov.yml * try to make two settings exclusive * Refactor some code, and increase the unit test code coverage for `src/main.jl` (#481) * Revert the changes to `codecov.yml` (#482) * Lower Codecov threshold to 99% because of GitHub Merge Queue limitations (#484) --------- Co-authored-by: Eric Hanson <5846501+ericphanson@users.noreply.github.com> Co-authored-by: mattBrzezinski <matt.brzezinski@invenia.ca>
to help with #477
docs: https://docs.codecov.com/docs/common-recipe-list#set-status-checks-to-block-coverage