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 17110-9967e23) Lines: 92194 104393 88.3 %
Date: 2014-11-26 Functions: 8194 9085 90.2 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 54041 72908 74.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
71.2%71.2%
71.2 % 1025 / 1439 80.9 % 89 / 110 49.0 % 393 / 802
language
71.8%71.8%
71.8 % 8062 / 11235 77.6 % 851 / 1097 56.1 % 4396 / 7837
headers
89.0%89.0%
89.0 % 1160 / 1303 87.6 % 480 / 548 82.8 % 512 / 618
kernel/gmp
90.9%90.9%
90.9 % 748 / 823 98.3 % 57 / 58 81.2 % 522 / 643
modules
91.4%91.4%
91.4 % 10262 / 11232 97.1 % 597 / 615 75.7 % 5784 / 7637
basemath
91.4%91.4%
91.4 % 67460 / 73782 93.6 % 5728 / 6117 77.6 % 39642 / 51070
kernel/none
91.7%91.7%
91.7 % 3163 / 3449 84.3 % 354 / 420 74.7 % 2670 / 3574

Generated by: LCOV version 1.9