Bug 38840 - Adding coverage analysis to unit tests

John Smith lbalbalba at gmail.com
Sun Aug 19 12:14:52 PDT 2012

On Sun, Aug 19, 2012 at 9:03 PM, Bjoern Michaelsen
<bjoern.michaelsen at canonical.com> wrote:
> Hi,
> We you run plain make in a module, it the default target already runs the
> unitcheck target. If you run make from the top-level, it also runs slowcheck.
Perhaps I got it all wrong, what gets run during the plain 'make' in
the toplevel is not really relevant here. The point is to figure out
how much code is actually 'tested' with the make check/etc target(s).

- First you run a plain make in the top level directory to build LO
(with analysis stuff enabled).
- then you create a 'baseline' with lcov (sort of create a 'before
snapshot' of LO)
- *then* you run all your tests (whatever they may be)
- then you re-run lcov to create an 'after snapshot'
- then you compare the 'before' and 'after' snapshots, and you can
tell what code was actually executed and therefore tested by your

At least, thats the way I understand it to be.

When I run 'make help' I get this :

       unitcheck        run unit tests
       slowcheck        run slow unit tests
       subsequentcheck  run system tests (requires full installation)
       check            run unit tests and if in toplevel subsequentcheck

Which gives me the idea that, when run from the top level, 'make
check' also runs 'make subsequentcheck ', and that it would make sense
to also run 'make unitcheck' and 'make slowcheck' here ? Or am I
missing something ?

Thanks for the feedback,


John Smith.

More information about the LibreOffice mailing list