Coverage.py v3.4 beta 2: uncovered files

Monday 6 September 2010This is 14 years old. Be careful.

I just posted Coverage.py v3.4 beta 2, the latest version of my code coverage measurement tool for Python. The biggest change is now if you specify --source to tell coverage where to find source files, it will identify file that weren’t executed at all, and add their 0% coverage to the final report. This has been a highly requested feature for a long time, and for good reason: what’s the point in measuring lines that aren’t executed if entire files slip by unnoticed?

But unexecuted files are only detected if --source is specified, because otherwise coverage.py won’t know where to search for files. I don’t know if there’s a useful default for something like this. Let me know if you have any interesting ideas.

A small but interesting change: coverage percentages will now only be reported as 100% or 0% if they are truly all or nothing. In the past, you could have 99.6% rounded to 100%, or 0.4% rounded to 0%.

Comments

Add a comment:

Ignore this:
Leave this empty:
Name is required. Either email or web are required. Email won't be displayed and I won't spam you. Your web site won't be indexed by search engines.
Don't put anything here:
Leave this empty:
Comment text is Markdown.