Skip to content
This repository has been archived by the owner on Jun 10, 2021. It is now read-only.

Block PRs from getting merged if they decrease coverage #38

Open
1 task
thomas-moulard opened this issue Dec 11, 2019 · 5 comments
Open
1 task

Block PRs from getting merged if they decrease coverage #38

thomas-moulard opened this issue Dec 11, 2019 · 5 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@thomas-moulard
Copy link
Member

Description

CodeCov can block PRs from getting merged if a certain threshold is not met (either relative or absolute), see https://docs.codecov.io/docs/commit-status

We should agree on some value and enable this.

Test Plan

  • Manual testing - set the threshold very high, verify that the build fails, then set it back to an appropriate value.

Documentation Plan

n/a

Release Plan

n/a

Acceptance Criteria

  • Code has been implemented, reviewed and merged.

Once all above items are checked, this story can be moved to done.

Resources

@thomas-moulard
Copy link
Member Author

@dabonnie PTAL

@dabonnie
Copy link
Contributor

I agree, though I'm not sure what value is reasonable. Should we initially try to enforce no decreased coverage?

@thomas-moulard
Copy link
Member Author

👍 That'd be great. We may allow some decrease to avoid blocking PRs containing code really hard to trigger (e.g. actually reading /proc).

@dabonnie
Copy link
Contributor

dabonnie commented Jan 8, 2020

I initially tried blocking with the default setting (no coverage) and it was too strict. I think we need to understand all our of partial hits, especially in the unit test files, before we enable blocking PRs based on coverage.

@mm318
Copy link
Member

mm318 commented Jan 9, 2020

I have a feeling that every ASSERT_/EXPECT_ statement we use in our tests contribute to missed branch coverage, because the failure branches are never hit since our tests are always passing.

@emersonknapp emersonknapp added enhancement New feature or request help wanted Extra attention is needed labels Mar 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants