Condition Coverage

lib/PDF/Data.pm
Criterion Covered Total %
condition 0 336 0.0


and 3 conditions

line !l l&&!r l&&r condition
89 0 0 0 $x and $y
0 0 0 $x and $y and $x > 0
0 0 0 $x and $y and $x > 0 and $y > 0
96 0 0 0 $x and $y
0 0 0 $x and $y and $x > 0
0 0 0 $x and $y and $x > 0 and $y > 0
205 0 0 0 $i < $#objects and $objects[$i + 1][1]{'type'} eq "dict"
771 0 0 0 defined $value and !defined($hash->{$key}) || $hash->{$key} ne $value
0 0 0 not defined $value and exists $hash->{$key}
876 0 0 0 defined $length and not ref $length
0 0 0 defined $length and not ref $length and substr($_, $length) =~ /\A($s*endstream$ws)/d
1001 0 0 0 ref $object and builtin::reftype($object) eq "SCALAR"
1023 0 0 0 $object->{'Length'} and length $object->{'-data'} > $object->{'Length'}
1112 0 0 0 ($object->{'Type'} // "") eq "/ExtGState" and $key eq "Font"
0 0 0 ($object->{'Type'} // "") eq "/ExtGState" and $key eq "Font" and &is_array($object->{'Font'})
0 0 0 ($object->{'Type'} // "") eq "/ExtGState" and $key eq "Font" and &is_array($object->{'Font'}) and &is_hash($object->{'Font'}[0])
0 0 0 $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key}
0 0 0 $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key} and &is_hash($object->{$key})
0 0 0 &is_hash($object->{$key}) and $object->{$key}{'-data'} || $object->{$key}{'Kids'} || ($object->{$key}{'Type'} // '') =~ m[^/(?:Filespec|Font)$]d
0 0 0 ($object->{'S'} // "") eq "/Thread" and $key eq "D"
0 0 0 ($object->{'S'} // "") eq "/Hide" and $key eq "T"
0 0 0 $key =~ /^(?:Annots|B|C|CO|Fields|K|Kids|O|Pages|TrapRegions)$/d and &is_array($object->{$key})
1176 0 0 0 defined $object and not $objects->[0]{$object}
1191 0 0 0 ref $object and $seen->{$object}++
1196 0 0 0 &is_array($object) and not grep({ref $_;} @{$object;})
1200 0 0 0 $self->{'-compress'} || $object->{'-compress'} and not $self->{'-decompress'} || $object->{'-decompress'}
1257 0 0 0 $spaces eq " " and not $self->{'-minify'}
1292 0 0 0 ref $object and $seen->{$object}
0 0 0 &is_array($object) and not grep({ref $_;} @{$object;})
1293 0 0 0 ref $object and $seen->{$object}
0 0 0 &is_array($object) and not grep({ref $_;} @{$object;})

or 2 conditions

line l !l condition
90 0 0 $x ||= "LETTER"
153 0 0 $file // "-"
240 0 0 $file // "-"
319 0 0 $mode //= ""
322 0 0 $file // ""
349 0 0 $file // "-"
362 0 0 $stream->{'-data'} //= ""
379 0 0 $content_stream->{'-data'} // ""
450 0 0 $_ || 0
574 0 0 $page_tree_node->{'Count'} || 0
590 0 0 $contents->{'-data'} //= ""
622 0 0 $xobject->{'-data'} //= ""
636 0 0 $stream->{'-data'} // ""
648 0 0 $stream->{'-data'} // ""
0 0 $objects ||= [$self->parse_objects({}, $stream->{'-data'} // "", 0)]
793 0 0 $hash->{$key} ||= {}
866 0 0 $stream->{'Type'} // ""
932 0 0 $data // ""
1008 0 0 $gen ||= 0
1022 0 0 $object->{'-data'} //= ""
1112 0 0 $object->{'Type'} // ""
0 0 $object->{'S'} // ""
0 0 $object->{'S'} // ""
1173 0 0 $object->{'-data'} //= ""
1199 0 0 $object->{'-data'} //= ""
1226 0 0 $object->{'-data'} //= ""
1262 0 0 $gen ||= 0
1303 0 0 $priority{$a} // 0
0 0 $priority{$b} // 0
1336 0 0 $gen ||= 0
1347 0 0 $priority{$a} // 0
0 0 $priority{$b} // 0
1385 0 0 $gen ||= 0

or 3 conditions

line l !l&&r !l&&!r condition
48 0 0 0 builtin::blessed($self) || $self
96 0 0 0 $self->{'-file'} || ()
176 0 0 0 builtin::blessed($self) || $self
183 0 0 0 $self->{'-file'} || ()
189 0 0 0 $self->{'-file'} || ()
205 0 0 0 $self->{'-file'} || ()
212 0 0 0 $self->{'-file'} || ()
234 0 0 0 $time //= time
265 0 0 0 $time //= time
316 0 0 0 not defined $file or $file eq ""
440 0 0 0 $time //= time
556 0 0 0 $self->{'-file'} || ()
558 0 0 0 $self->{'-file'} || ()
559 0 0 0 $self->{'-file'} || ()
566 0 0 0 $self->{'-file'} || ()
575 0 0 0 $self->{'-file'} || ()
589 0 0 0 $self->{'-file'} || ()
621 0 0 0 $self->{'-file'} || ()
637 0 0 0 $self->{'-file'} || ()
754 0 0 0 ${$stream;} =~ /(^|[$ss)>\[\]{}])$/d or $object =~ m(^[$ss()<>\[\]{}/%])d
771 0 0 0 !defined($hash->{$key}) || $hash->{$key} ne $value
772 0 0 0 $self->{'-file'} || ()
775 0 0 0 $self->{'-file'} || ()
826 0 0 0 $self->{'-file'} || ()
0 0 0 $pairs[$i][1]{'name'} // croak(join(": ", $self->{'-file'} || (), "Byte offset ${offset}: Dictionary key is not a name!\n"))
839 0 0 0 $token eq "obj" or $token eq "R"
843 0 0 0 $self->{'-file'} || ()
844 0 0 0 $gen->[0] || ()
850 0 0 0 $self->{'-file'} || ()
858 0 0 0 $self->{'-file'} || ()
859 0 0 0 $self->{'-file'} || ()
862 0 0 0 $self->{'-file'} || ()
868 0 0 0 $self->{'-file'} || ()
870 0 0 0 $self->{'-file'} || ()
872 0 0 0 $self->{'-file'} || ()
880 0 0 0 $self->{'-file'} || ()
894 0 0 0 $self->{'-file'} || ()
897 0 0 0 $object->[1]{'offset'} // $offset
901 0 0 0 $self->{'-file'} || ()
915 0 0 0 $self->{'-file'} || ()
919 0 0 0 $objects[-1][1]{'offset'} //= $offset
957 0 0 0 $status == Z_OK() or $status == Z_STREAM_END()
961 0 0 0 $self->{'-file'} || ()
989 0 0 0 $self->{'-file'} || ()
990 0 0 0 $self->{'-file'} || ()
1009 0 0 0 $self->{'-file'} || ()
1025 0 0 0 $object->{'Length'} ||= $len
1027 0 0 0 $self->{'-file'} || ()
1112 0 0 0 $key =~ /^(?:Data|First|ID|Last|Next|Obj|Parent|ParentTree|Popup|Prev|Root|StmOwn|Threads|Widths)$/d or $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key} and &is_hash($object->{$key})
0 0 0 $object->{$key}{'-data'} || $object->{$key}{'Kids'} || ($object->{$key}{'Type'} // '') =~ m[^/(?:Filespec|Font)$]d
0 0 0 $key =~ /^(?:Data|First|ID|Last|Next|Obj|Parent|ParentTree|Popup|Prev|Root|StmOwn|Threads|Widths)$/d or $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key} and &is_hash($object->{$key}) or &is_hash($object->{$key}) and $object->{$key}{'-data'} || $object->{$key}{'Kids'} || ($object->{$key}{'Type'} // '') =~ m[^/(?:Filespec|Font)$]d
0 0 0 $key =~ /^(?:Data|First|ID|Last|Next|Obj|Parent|ParentTree|Popup|Prev|Root|StmOwn|Threads|Widths)$/d or $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key} and &is_hash($object->{$key}) or &is_hash($object->{$key}) and $object->{$key}{'-data'} || $object->{$key}{'Kids'} || ($object->{$key}{'Type'} // '') =~ m[^/(?:Filespec|Font)$]d or ($object->{'S'} // "") eq "/Thread" and $key eq "D"
0 0 0 $key =~ /^(?:Data|First|ID|Last|Next|Obj|Parent|ParentTree|Popup|Prev|Root|StmOwn|Threads|Widths)$/d or $key =~ /^(?:AN|Annotation|B|C|CI|DocMDP|F|FontDescriptor|I|IX|K|Lock|N|P|Pg|RI|SE|SV|V)$/d and ref $object->{$key} and &is_hash($object->{$key}) or &is_hash($object->{$key}) and $object->{$key}{'-data'} || $object->{$key}{'Kids'} || ($object->{$key}{'Type'} // '') =~ m[^/(?:Filespec|Font)$]d or ($object->{'S'} // "") eq "/Thread" and $key eq "D" or ($object->{'S'} // "") eq "/Hide" and $key eq "T"
1192 0 0 0 $self->{'-file'} || ()
1200 0 0 0 $self->{'-compress'} || $object->{'-compress'}
0 0 0 $self->{'-decompress'} || $object->{'-decompress'}
1227 0 0 0 $self->{'-file'} || ()
1303 0 0 0 ($priority{$a} // 0) <=> ($priority{$b} // 0) or fc $a cmp fc $b
1347 0 0 0 ($priority{$a} // 0) <=> ($priority{$b} // 0) or fc $a cmp fc $b