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-bordeaux.fr machine (x86_64 architecture), and agregate them in the final report:

The target is to exceed 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 - graph - plotport.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29115-f22e516b23) Lines: 1216 1425 85.3 %
Date: 2024-04-20 08:07:50 Functions: 111 131 84.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Appendx 170176
Appendy 235176
DTOL 158839
Draw 76
Rchain 35743
_box 130
_line 214
_move 772
_ploth 44
_plothexport 53
_psdraw 0
_psdraw_scale 0
check_rect 24830
check_rect_init 24522
chk_8bit 0
clipline 120
color_to_rgb 11174
colormap_to_color 11170
colorname_to_rgb 11174
cp 460
cpd 0
dblV_from_RgV 504
fmt_convert 135
freeobj 36063
gen_draw 135
gendraw 44
get_xy 138192
get_xy_from_vec 40256
gtodblList 42
hex2 0
initrect_get_arg 180
initrect_i 300
long_to_rgb 19630
param_recursion 138104
pari_get_fmtplot 71
pari_get_psplot 49
pari_get_svgplot 86
pari_init_graphics 1830
pari_kill_plot_engine 1820
pari_plot_by_file 0
pari_set_plot_engine 1820
parploth 0
parplothexport 14
plotbox 18
plotclip 20
plotcolor 8
plotcopy 36
plotcursor 47
plotdraw 44
plotell 0
plotexport 64
ploth 44
ploth0 44
plothexport 39
plothexport0 39
plothraw 8
plothraw_i 26
plothrawexport 18
plothsizes 8
plotinit 90
plotkill 296
plotline 18
plotlines 36
plotlinetype 10862
plotmove 119
plotmove0 909
plotpoint 18
plotpoint0 36
plotpoints 36
plotpoints0 36
plotpointsize 0
plotpointtype 18
plotrbox 18
plotrecth 9983
plotrecth0 7
plotrecth_i 10080
plotrecthin 10080
plotrecthraw 16
plotrecthraw_i 42
plotrecthrawin 10106
plotrline 18
plotrmove 18
plotrpoint 18
plotscale 34
plotscale0 164
plotstring 464
ps_arc 0
ps_fillarc 0
ps_fillrect 0
ps_line 2765
ps_lines 28
ps_point 860
ps_points 21
ps_rect 56
ps_sc 2989
ps_string 98
psdraw 0
psploth 0
psploth0 0
psplothraw 0
rect2ps 49
rect2ps_i 49
rect2svg 86
rectarc0 0
rectbox0 166
rectline0 250
rectlines0 10518
rectsplines 8
rectticks 520
rgb_to_long 11174
rmiddle 208940
set_range 20212
set_xrange 178796
set_yrange 245388
single_recursion 91404
spline_eval 234176
svg_color 5467
svg_ell 0
svg_fillell 0
svg_fillrect 0
svg_head 86
svg_line 4905
svg_lines 75
svg_point 992
svg_points 32
svg_rect 104
svg_rescale 127122
svg_tail 86
svg_text 222
wxy_init 108
wxy_n 108

Generated by: LCOV version 1.14