Branch Coverage

blib/lib/PDF/Builder/Resource/XObject/Image/PNG.pm
Criterion Covered Total %
branch 44 78 56.4


line true false branch
117 0 5 if (defined $opts{'-nouseIPL'} and not defined $opts{'nouseIPL'})
118 0 5 if (defined $opts{'-notrans'} and not defined $opts{'notrans'})
119 0 5 if (defined $opts{'-name'} and not defined $opts{'name'})
120 0 5 if (defined $opts{'-compress'} and not defined $opts{'compress'})
123 0 5 if (exists $opts{'name'})
128 0 5 if ref $class
131 0 5 unless $self->is_obj($pdf)
137 1 4 if (ref $file) { }
140 1 3 unless open $fh, "<", $file
152 4 14 if ($buf eq 'IHDR') { }
2 12 elsif ($buf eq 'PLTE') { }
4 8 elsif ($buf eq 'IDAT') { }
0 8 elsif ($buf eq 'tRNS') { }
4 4 elsif ($buf eq 'IEND') { }
155 0 4 if $cm
156 0 4 if $im
157 0 4 if $fm
181 0 4 if ($cs == 0) { }
0 4 elsif ($cs == 2) { }
2 2 elsif ($cs == 3) { }
0 2 elsif ($cs == 4) { }
2 0 elsif ($cs == 6) { }
184 0 0 if ($bpc > 8) { }
196 0 0 if (defined $trns and not $opts{'notrans'})
204 0 0 if ($bpc > 8) { }
216 0 0 if (defined $trns and not $opts{'notrans'})
239 0 2 if ($bpc > 8) { }
256 0 2 if (defined $trns and not $opts{'notrans'})
291 0 0 if ($bpc > 8) { }
305 0 0 unless ($opts{'notrans'})
337 0 2 if ($bpc > 8) { }
351 2 0 unless ($opts{'notrans'})
426 82304 11936 if ($pa <= $pb and $pa <= $pc) { }
11154 782 elsif ($pb <= $pc) { }
448 0 574 if ($filter == 0) { }
18 556 elsif ($filter == 1) { }
494 62 elsif ($filter == 2) { }
0 62 elsif ($filter == 3) { }
62 0 elsif ($filter == 4) { }