Branch Coverage

lib/File/Type/WebImages.pm
Criterion Covered Total %
branch 19 24 79.1


line true false branch
16 1 4 unless defined $argument
18 2 2 if (length $argument > 1024 or $argument =~ /\n/)
24 0 2 if (-e $argument)
25 0 0 if (not -d $argument) { }
52 1 13 unless defined $data
54 3 10 if ($data =~ /^\x89PNG/) { }
3 7 elsif ($data =~ /^GIF8/) { }
2 5 elsif ($data =~ /^BM/) { }
64 3 2 if (length $data > 1)
66 0 3 if (defined $substr and $substr =~ /^PNG/)
70 3 2 if (length $data > 0)
72 3 0 if ("\377\330" eq $substr)