# pytest-cov

> Pytest plugin for measuring coverage

Source: https://talira.ai/catalog/pytest-cov-9qgpya10
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Plugin
- Categories: [developer tools / testing / code coverage](https://talira.ai/categories/developer-tools/testing/code-coverage), [languages / python](https://talira.ai/categories/languages/python)
- Licence: MIT[^1]
- Pricing: Free and open source[^1]
- Pricing notes: Free and open source.
- Free tier: yes[^1]
- Backed by: [pytest-dev](https://talira.ai/orgs/pytest-dev.md)

pytest-cov is a [pytest](https://talira.ai/catalog/pytest-5repc51s.md) plugin that measures code coverage with coverage.py while your tests run (pytest --cov). Compared with coverage run, it erases and combines .coverage files automatically and reports by default, supports detailed coverage contexts (the full test name as each line's context), works with pytest-xdist's distributed and remote testing, and keeps pytest's normal import behaviour. Every coverage.py feature is available through its command-line options or coverage's config file.

## Links

- GitHub: https://github.com/pytest-dev/pytest-cov
- Docs: https://pytest-cov.readthedocs.io/

## Problems it solves

- measure test coverage for my Python project with pytest
- get coverage reports when running tests in parallel with pytest-xdist
- fail CI when Python test coverage drops below a threshold
- see which test covered each line of my Python code

## Features

- coverage while pytest runs (--cov)
- automatic erase and combine of .coverage files
- coverage contexts per test
- pytest-xdist support
- all coverage.py options and config

## Trust

Overall: 0.27 out of 1.
Signals: backing 0.30, extensibility 0.00.

- backed by pytest-dev

Warnings:

- GitHub activity not fetched yet

## Related

- Works with [pytest](https://talira.ai/catalog/pytest-5repc51s.md)

## Alternatives

- [Codecov](https://talira.ai/catalog/codecov-pd0rdj0n.md): More than just code coverage.
- [SimpleCov](https://talira.ai/catalog/simplecov-sp7ythxb.md): Code coverage for Ruby with a powerful configuration library and automatic merging of coverage across test suites
- [Coveralls](https://talira.ai/catalog/coveralls-m8sgpjdw.md): We help you deliver code confidently by showing which parts of your code aren't covered by tests.
- [DeepSource](https://talira.ai/catalog/deepsource-fd2qg7dz.md): AI code review platform that combines static analysis with AI review agents

## Sources

[^1]: https://github.com/pytest-dev/pytest-cov/blob/master/LICENSE (checked 23 Nov 2026)
