pytest-cov icon indicating copy to clipboard operation
pytest-cov copied to clipboard

--cov-branch does not seem to be mentioned in the documentation

Open szabgab opened this issue 7 years ago • 5 comments

At least I could not find it here: http://pytest-cov.readthedocs.io/en/latest/reporting.html

I found it accidentally. It would be nice if it was included in the docs.

szabgab avatar Jan 10 '18 20:01 szabgab

Agreed, the only mention of --cov-branch is in the changelog.

Also, it does not seem to be documented anywhere weather or not the appending --cov-branch will only test branch coverage or will test branch coverage additionally to normal line coverage.

kennell avatar Aug 14 '18 14:08 kennell

Looks like it's on the configuration page: https://pytest-cov.readthedocs.io/en/latest/config.html#reference

I agree that it would be nice to have a small section about it on the reporting page. Something like:

The --cov-branch flag enables branch coverage, where every possible branch path through the code is included. The generated report will then show which branch paths were not executed along with the lines that were not covered.

mjhea0 avatar Oct 04 '19 13:10 mjhea0

Make a PR :)

ionelmc avatar Oct 04 '19 14:10 ionelmc

On it

mjhea0 avatar Oct 04 '19 14:10 mjhea0

https://github.com/pytest-dev/pytest-cov/pull/347

mjhea0 avatar Oct 04 '19 18:10 mjhea0