Branch Coverage

blib/lib/Path/Abstract/Underload.pm
Criterion Covered Total %
branch 84 94 89.3


line true false branch
37 2 1123 ref $_ && (ref $_ eq 'Path::Abstract::Underload' || blessed $_ && $_->isa('Path::Abstract::Underload')) ? :
38 3 1114 ref $_ eq 'ARRAY' ? :
39 1073 52 length $_ ? :
50 786 0 unless $path eq './'
53 755 31 unless $path eq '/'
54 110 676 if $path ne '/' and $trailing
56 523 263 unless $leading
84 11 8 if $Path::Abstract::_0_093_warn
91 7 4 unless $self->is_tree
103 11 12 if $Path::Abstract::_0_093_warn
110 0 4 if $Path::Abstract::_0_093_warn
117 11 8 if $Path::Abstract::_0_093_warn
123 11 11 if $Path::Abstract::_0_093_warn
129 11 54 if $self->is_empty
131 0 54 if 1 == @path and '' eq $path[0]
133 25 29 if (0 > $index) { }
19 10 elsif (not defined $path[0] && length $path[0]) { }
139 6 48 if $index >= @path
140 3 45 if $index == @path - 1 and not defined $path[$index] or not length $path[$index]
141 3 45 unless defined $path[$index] and length $path[$index]
178 0 10 unless @_
187 0 30 if (@_ and not defined $_[0]) { }
26 4 elsif (ref $_[0] eq '') { }
195 5 25 if (ref $_[0] eq 'HASH') { }
203 1 29 if ('*' eq $matcher)
206 0 30 if (ref $matcher eq 'Regexp') { }
30 0 elsif ($matcher eq '' or $matcher =~ /^\d+$/) { }
216 10 20 if (not defined $extension) { }
217 2 8 if $self->is_empty or $self->is_root
221 5 15 if ('' eq $extension) { }
3 12 elsif (not $extension =~ /^\./) { }
227 6 14 if ($self->is_empty or $self->is_root) { }
231 13 1 if ($ending =~ s/$matcher/$extension/) { }
251 0 190 if $self->is_empty
253 57 133 unless defined $count
255 84 106 if ($count =~ s/([\^\$\*])$//)
256 64 20 if $1 ne '$'
257 52 32 if $1 ne '^'
259 138 52 unless $re
260 24 166 unless length $count
267 262 11 if ($$self =~ s/$re//) { }
269 262 0 if $popped
270 86 176 unless (length $$self)
271 32 54 if ($greedy_lead) { }
336 13 137 if $self->is_empty
343 16 53 if $self->is_empty
376 0 5 if ($@) { }