[tor-dev] lcov test coverage reports

Nick Mathewson nickm at freehaven.net
Mon Jun 16 20:07:38 UTC 2014


On Mon, Jun 16, 2014 at 10:55 AM, Nick Mathewson <nickm at freehaven.net> wrote:
 [...]
> Additionally, one thing that I'd really love to see -- though I don't
> at all know whether lcov can do this as it stands -- is a semantic
> diff between two coverage outputs.  When writing new unit tests at
> random, or when checking functions that you know need coverage, it's
> useful to ask "Which lines are not covered?"  But for validating new
> code and checking patches, the question I want to ask is "Which *new*
> or *changed* lines are not covered?"
>
> We kinda have a script for this now, but learning to read its outputs
> is not as easy as I'd like.

It would appear at first glance that you can do something *almost*
like this using lcov --diff and genhtml --highlight.  Those options
together seem to be able to let you know about lines that used to be
covered but which are no longer covered.  (I'm hoping to learn about
likes that changed or started to exist which are uncovered.)


More information about the tor-dev mailing list