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 16358-a11f489) Lines: 84691 97092 87.2 %
Date: 2014-04-11 Functions: 7528 8406 89.6 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 50879 69501 73.2 %

Directory Sort by name Line Coverage Sort by line coverage Functions Sort by function coverage Branches Sort by branch coverage
mt
16.3%16.3%
16.3 % 36 / 221 44.4 % 16 / 36 7.0 % 6 / 86
gp
32.4%32.4%
32.4 % 585 / 1807 33.7 % 59 / 175 22.6 % 310 / 1371
graph
63.4%63.4%
63.4 % 912 / 1439 76.4 % 84 / 110 47.1 % 378 / 802
language
71.9%71.9%
71.9 % 7270 / 10116 78.0 % 760 / 974 57.1 % 4020 / 7045
modules
90.5%90.5%
90.5 % 10057 / 11107 96.5 % 578 / 599 74.4 % 5587 / 7511
kernel/none
91.0%91.0%
91.0 % 3067 / 3372 83.6 % 346 / 414 75.7 % 2752 / 3634
basemath
91.0%91.0%
91.0 % 60898 / 66940 93.8 % 5162 / 5503 77.0 % 36815 / 47812
kernel/gmp
91.0%91.0%
91.0 % 746 / 820 98.3 % 57 / 58 81.5 % 524 / 643
headers
88.2%88.2%
88.2 % 1120 / 1270 86.8 % 466 / 537 81.6 % 487 / 597

Generated by: LCOV version 1.9