Testing and gcov
dbn.lists at gmail.com
Wed Oct 3 05:45:32 PDT 2012
Last week I added optional use of gcov to see how much test coverage
our code was getting. The initial results weren't as bad as I
expected, but I added a bunch more tests to exercise more of the code.
Some tests are for features which had never been touched in the
testsuite at all, like SYSROOT_DIR and uninstalled handling. In the
process I even found a bunch of dead code that had been there since
the initial port to C but never used as far as I could tell. Now the
story looks a lot better from gcov. From "./configure --with-gcov &&
/usr/bin/gcov pkg.h pkg.c parse.h parse.c main.c
Lines executed:87.12% of 559
Lines executed:100.00% of 6
Lines executed:82.11% of 492
Lines executed:91.13% of 293
For some reason, it insists on checking gstring.h, and I haven't
bothered to figure out why yet. Anyway, if you can run "make check" on
master and see if the tests still pass for you, that would be helpful.
Especially on Windows where we have some different pathways.
More information about the pkg-config