Using coverage with pytests is a very useful tool.
Html reporting allows for nice output, however through command line, can't find an option to modify the default output directory (htmlcov)
example command line:
python -m pytest lib_being_tested\tests --cov lib_being_tested.module --cov-report=html
This configuration option isn't part of pytest-cov
.
In the configuration file for the underlying tool coverage.py
, which is called .coveragerc
by default, you can add:
[html]
directory = differentname
See the documentation for details: https://github.com/nedbat/coveragepy/blob/master/doc/config.rst
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments