I am new to coverage and ran into a strange problem. My coverage is taking my virtual environment site packages into account. Here is the output of the coverage run:
<
If using pytest, you can specify exclusive paths or files to test in setup.cfg
(see docs):
[pytest]
# a directory
testpaths = tests
# exact file(s)
python_files = tests/test1.py tests/test2.py
It looks like if you include the python_files
and testpaths
parameters, then the python_files
will only be used.