[Python-Dev] C code coverage report with lcov

Antoine Pitrou solipsis at pitrou.net
Mon Jul 29 21:48:33 CEST 2013


On Mon, 29 Jul 2013 21:31:02 +0200
Christian Heimes <christian at python.org> wrote:
> Am 29.07.2013 19:58, schrieb Brett Cannon:
> > I took a quick poke around and it seems some things are legitimately not
> > being executed, while others are error conditions that we wouldn't
> > expect to occur (e.g. memory exhaustion). If we ever decide to get
> > serious about code coverage (both C and Python code) we may need to have
> > a discussion as a group about our feelings related to pragmas dictating
> > when code should be left out of coverage reports.
> 
> Yeah, object allocation and creation checks as well as verification of
> operating system API call are reason for lots branch and line misses.
> I'm not sure what we can do about that. I don't want to plaster the code
> with LCOV_EXCL_LINE comments.

Ideally, we should run coverage runs on different systems (Unices,
Windows...) and merge the results together, so that we know which paths
are really uncovered.

Regards

Antoine.




More information about the Python-Dev mailing list