Skip to content

Commit

Permalink
--report-type='' implies no --cov-fail-under
Browse files Browse the repository at this point in the history
  • Loading branch information
terencehonles committed Apr 14, 2018
1 parent 861955b commit 4645a0e
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
1 change: 1 addition & 0 deletions AUTHORS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,4 @@ Authors
* Zoltan Kozma - https://github.com/kozmaz87
* Francis Niu - https://flniu.github.io
* Jannis Leidel - https://github.com/jezdez
* Terence Honles - https://github.com/terencehonles
9 changes: 9 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
Changelog
=========

2.5.2 (2018-04-14)
------------------

* Specifying ``--cov-report=`` will not output any report information and
will not check minimum coverage which may be specified with
``--cov-fail-under=MIN`` or through the config. This change is to allow
using ``--cov-append`` in future runs without reporting failure too early.


2.5.1 (2017-05-11)
------------------

Expand Down
3 changes: 2 additions & 1 deletion src/pytest_cov/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,8 @@ def pytest_testnodedown(self, node, error):
pytest_testnodedown.optionalhook = True

def _should_report(self):
return not (self.failed and self.options.no_cov_on_fail)
return (self.options.cov_report
and not (self.failed and self.options.no_cov_on_fail))

def _failed_cov_total(self):
cov_fail_under = self.options.cov_fail_under
Expand Down

0 comments on commit 4645a0e

Please sign in to comment.