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 17097-9391e68) Lines: 91596 104344 87.8 %
Date: 2014-11-21 Functions: 8123 9081 89.5 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 53795 72860 73.8 %

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
68.2%68.2%
68.2 % 7648 / 11206 72.3 % 792 / 1096 54.0 % 4216 / 7813
kernel/none
91.7%91.7%
91.7 % 3163 / 3449 84.3 % 354 / 420 74.7 % 2670 / 3574
modules
91.3%91.3%
91.3 % 10248 / 11224 97.1 % 595 / 613 75.6 % 5763 / 7621
basemath
91.4%91.4%
91.4 % 67412 / 73770 93.6 % 5726 / 6116 77.6 % 39616 / 51062
kernel/gmp
90.9%90.9%
90.9 % 748 / 823 98.3 % 57 / 58 81.2 % 522 / 643
headers
88.9%88.9%
88.9 % 1159 / 1303 87.6 % 480 / 548 82.5 % 510 / 618

Generated by: LCOV version 1.9