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 17953-c39f2e6) Lines: 98471 110580 89.0 %
Date: 2015-08-28 Functions: 8728 9611 90.8 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 58115 76954 75.5 %

Directory Sort by name Line Coverage Sort by line coverage Functions Sort by function coverage Branches Sort by branch coverage
gp
30.9%30.9%
30.9 % 272 / 879 28.2 % 22 / 78 16.9 % 103 / 609
graph
65.5%65.5%
65.5 % 937 / 1430 75.7 % 84 / 111 50.3 % 407 / 809
language
74.0%74.0%
74.0 % 8551 / 11553 78.6 % 868 / 1104 59.8 % 4788 / 8003
mt
84.3%84.3%
84.3 % 182 / 216 69.4 % 25 / 36 74.4 % 61 / 82
kernel/none
91.9%91.9%
91.9 % 3178 / 3458 84.6 % 357 / 422 75.5 % 2701 / 3578
modules
91.9%91.9%
91.9 % 12798 / 13932 96.7 % 837 / 866 78.1 % 7239 / 9265
basemath
91.8%91.8%
91.8 % 70631 / 76967 93.9 % 5989 / 6380 78.3 % 41768 / 53337
kernel/gmp
90.9%90.9%
90.9 % 748 / 823 98.3 % 57 / 58 81.6 % 525 / 643
headers
88.8%88.8%
88.8 % 1174 / 1322 87.9 % 489 / 556 83.3 % 523 / 628

Generated by: LCOV version 1.9