coverage run --omit='tests/*' -m pytest

Category: Python & pip

coverage run --omit='tests/*' -m pytest

Collect coverage while omitting test files themselves

Collects coverage but excludes test files from the report to see only production code coverage.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.