Coverage coverage.py on GitHub and on PyPI $ pip install coverage $ coverage run -m unittest $ coverage report $ coverage html $ cd htmlcov/ $ open index.html coverage-badge.py