Branch Coverage

blib/lib/IIIF/Magick.pm
Criterion Covered Total %
branch 34 44 77.2


line true false branch
19 0 0 unless -f $file
22 0 0 unless `$cmd` =~ /^(\d+)x(\d+)$/u
40 1 20 if ($req->{'region'} eq 'square') { }
1 19 elsif (my $region_px = $req->{'region_px'}) { }
3 16 elsif (my $region_pct = $req->{'region_pct'}) { }
55 2 1 if ($x or $y)
66 2 19 if ($req->{'size_pct'}) { }
6 13 elsif ($req->{'size_px'}) { }
72 1 5 if ($x and not $y) { }
1 4 elsif (not $x and $y) { }
2 2 elsif ($req->{'ratio'}) { }
87 2 19 if $req->{'mirror'}
88 2 19 if (my $degree = $req->{'degree'})
90 1 1 if ($degree - 90 * int($degree / 90))
96 1 20 if ($req->{'quality'} eq 'gray') { }
1 19 elsif ($req->{'quality'} eq 'bitonal') { }
110 0 1 if defined $in and $in ne ''
111 0 1 if defined $out and $out ne ''
112 0 1 if can_run('magick')
127 3 0 if ($^O eq 'MSWin32') { }
0 0 elsif (not $arg =~ qr"\A[\w,_+/.-]+\z"u) { }
128 1 2 unless ($arg =~ /\A[\w_+-]+\z/u)