Branch Coverage

blib/lib/Image/JPEG/EstimateQuality.pm
Criterion Covered Total %
branch 23 38 60.5


line true false branch
28 15 3 if (not ref $file) { }
1 2 elsif (ref $file eq 'SCALAR') { }
2 0 elsif (ref $file eq 'GLOB' or eval { do { $file->isa('IO::Handle') } }) { }
29 0 15 unless open $fh, '<', $file
36 0 1 unless open $fh, '<', $file
57 0 18 unless read $fh, $buf, 2
58 0 18 unless $buf eq "\377\330"
61 0 36 unless read $fh, $buf, 2
63 0 36 if ($buf eq "\377\330")
66 0 36 if ($buf eq "\377\332")
71 0 36 unless $marker eq "\377"
73 18 18 if ($buf ne "\377\333")
75 0 18 unless read $fh, $buf, 2
77 0 18 unless seek $fh, $len - 2, 1
82 0 18 unless read $fh, $buf, 2
85 0 18 unless $len >= 65
88 0 18 unless read $fh, $buf, $len
118 18 0 if ($is_8bit) { }
126 18 927 if ($sum < $sums_dqt[99 - $i])