Code coverage tests

This page documents the degree to which the PARI/GP source code is tested by our public test suite, distributed with the source distribution in directory src/test/. This is measured by the gcov utility; we then process gcov output using the lcov frond-end.

We test a few variants depending on Configure flags on the pari.math.u-bordeaux1.fr machine (x86_64 architecture), and agregate them in the final report:

The target is 90% coverage for all mathematical modules (given that branches depending on DEBUGLEVEL or DEBUGMEM are not covered). This script is run to produce the results below.

LCOV - code coverage report
Current view: top level Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 16962-5a32637) Lines: 88621 101827 87.0 %
Date: 2014-10-29 Functions: 7898 8895 88.8 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 52586 71888 73.1 %

Directory Sort by name Line Coverage Sort by line coverage Functions Sort by function coverage Branches Sort by branch coverage
mt
16.8%16.8%
16.8 % 36 / 214 44.4 % 16 / 36 7.3 % 6 / 82
gp
30.3%30.3%
30.3 % 278 / 916 26.2 % 22 / 84 18.0 % 116 / 645
graph
62.8%62.8%
62.8 % 904 / 1439 73.6 % 81 / 110 46.9 % 376 / 802
language
67.8%67.8%
67.8 % 7574 / 11168 71.7 % 782 / 1090 53.8 % 4203 / 7819
kernel/none
91.5%91.5%
91.5 % 3153 / 3445 84.0 % 352 / 419 74.7 % 2666 / 3570
modules
90.7%90.7%
90.7 % 10173 / 11216 96.3 % 591 / 614 74.8 % 5704 / 7621
basemath
90.6%90.6%
90.6 % 64605 / 71306 93.0 % 5522 / 5939 76.8 % 38488 / 50090
kernel/gmp
90.9%90.9%
90.9 % 748 / 823 98.3 % 57 / 58 81.2 % 522 / 643
headers
88.5%88.5%
88.5 % 1150 / 1300 87.2 % 475 / 545 82.0 % 505 / 616

Generated by: LCOV version 1.9