Branch Coverage

blib/lib/Sort/Naturally.pm
Criterion Covered Total %
branch 75 98 76.5


line true false branch
15 2 0 unless defined &DEBUG
23 0 2 if $x < 4
25 0 2 if $@
156 0 269 if @_ and ref $_[0] eq 'ARRAY'
0 269 if (@_ == 0) { }
0 269 elsif (@_ != 2) { }
0 269 $lc ? :
0 269 $lc ? :
10 37 if ($y =~ /^\d/ls) { }
20 249 if ($x eq $y) { }
47 202 elsif ($x =~ /^\d/ls) { }
29 173 elsif ($y =~ /^\d/ls) { }
217 10 $x =~ /^(\D+)/ls ? :
217 10 $y =~ /^(\D+)/ls ? :
56 171 if $x2 > $y2
0 217 $cmp ? :
0 30 unless $rv == $sv
30 187 if ($rv = $cmp ? &$cmp(substr($x, 0, $x2) . '', substr($y, 0, $x2) . '') : scalar(substr($x, 0, $x2) . '' cmp substr($y, 0, $x2) . ''))
217 10 if ($x2)
36 45 if $rv = $x2 <=> $1
0 0 if $rv = length $x2 <=> length $y2 || $x2 cmp $y2
81 0 if (length $x2 < 9 and length $1 < 9) { }
81 33 if ($y =~ s/^(\d+)//ls) { }
114 83 if ($x =~ s/^(\d+)//ls) { }
43 40 elsif ($y =~ s/^\d+//ls) { }
203 66 unless ($rv)
0 269 if ($a eq $b) { }
0 10 if @_ and ref $_[0] eq 'ARRAY'
0 10 unless @_ > 1 or wantarray
10 37 if ($y =~ /^\d/ls) { }
20 249 if ($x eq $y) { }
47 202 elsif ($x =~ /^\d/ls) { }
29 173 elsif ($y =~ /^\d/ls) { }
217 10 $x =~ /^(\D+)/ls ? :
217 10 $y =~ /^(\D+)/ls ? :
56 171 if $x2 > $y2
0 217 $cmp ? :
0 30 unless $rv == $sv
30 187 if ($rv = $cmp ? &$cmp(substr($x, 0, $x2) . '', substr($y, 0, $x2) . '') : scalar(substr($x, 0, $x2) . '' cmp substr($y, 0, $x2) . ''))
217 10 if ($x2)
36 45 if $rv = $x2 <=> $1
0 0 if $rv = length $x2 <=> length $y2 || $x2 cmp $y2
81 0 if (length $x2 < 9 and length $1 < 9) { }
81 33 if ($y =~ s/^(\d+)//ls) { }
114 83 if ($x =~ s/^(\d+)//ls) { }
43 40 elsif ($y =~ s/^\d+//ls) { }
203 66 unless ($rv)
0 269 if ($$a[0] eq $$b[0]) { }
0 110 $lc ? :