--report-type='' implies no --cov-fail-under #199
Closed
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.
Specifying
--cov-report=will not output any report information and will not check minimum coverage which may be specified with--cov-fail-under=MINor through the config. This change is to allow using--cov-appendin future runs without reporting failure too early.With this change, on the final build you will need to generate at least
--cov-report=termor runcoverage reportdirectlyI made this change because I want to declare
fail_underin my coverage config (for me it lives insetup.cfgwhich passes some other common options by usingaddopts(like mentioned in #195)), but my current test setup requires at least 2 passes runningpytestwhich initially the sequence would be:However, without the proposed PR the first test fails and I would have to ignore the exit code (which is not appropriate because the test suite may have actually failed)
With this change I can leave
fail_underas part of my coverage config instead of having to hardcode it in the CI runner or add an additional file/configuration option.