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 - language Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 16741-1378b1c) Lines: 7348 10230 71.8 %
Date: 2014-08-17 Functions: 770 988 77.9 %
Legend: Rating: low: < 75 % medium: >= 75 % high: >= 90 % Branches: 4093 7145 57.3 %

Filename Sort by name Line Coverage Sort by line coverage Functions Sort by function coverage Branches Sort by branch coverage
default.c
41.0%41.0%
41.0 % 184 / 449 45.6 % 26 / 57 22.4 % 68 / 303
hash.c
59.0%59.0%
59.0 % 69 / 117 75.0 % 12 / 16 42.6 % 29 / 68
eval.c
61.5%61.5%
61.5 % 781 / 1269 66.7 % 62 / 93 47.0 % 375 / 798
init.c
66.7%66.7%
66.7 % 766 / 1149 71.1 % 91 / 128 50.5 % 392 / 777
es.c
61.9%61.9%
61.9 % 1506 / 2431 68.8 % 192 / 279 51.4 % 965 / 1878
anal.c
69.7%69.7%
69.7 % 424 / 608 88.7 % 63 / 71 54.5 % 274 / 503
intnum.c
89.8%89.8%
89.8 % 850 / 947 94.6 % 87 / 92 63.5 % 396 / 624
sumiter.c
80.5%80.5%
80.5 % 800 / 994 90.0 % 63 / 70 63.4 % 486 / 766
compat.c
90.0%90.0%
90.0 % 54 / 60 96.6 % 28 / 29 68.6 % 24 / 35
parse.c
66.3%66.3%
66.3 % 167 / 252 100.0 % 5 / 5 68.5 % 185 / 270
parsec.h
92.2%92.2%
92.2 % 107 / 116 100.0 % 18 / 18 76.5 % 26 / 34
compile.c
86.7%86.7%
86.7 % 1225 / 1413 93.3 % 70 / 75 76.7 % 670 / 873
members.c
98.0%98.0%
98.0 % 290 / 296 96.4 % 53 / 55 93.9 % 201 / 214
parse.y
96.9%96.9%
96.9 % 125 / 129 - 0 / 0 100.0 % 2 / 2

Generated by: LCOV version 1.9