Branch Coverage

blib/lib/Mojo/Path.pm
Criterion Covered Total %
branch 40 40 100.0


line true false branch
14 12 1439 if (not length $parts->[$i] or $parts->[$i] eq '.' or $parts->[$i] eq '...') { }
1421 18 elsif ($i < 1 or $parts->[$i] ne '..' or $$parts[$i - 1] eq '..') { }
19 911 86 @$parts ? :
26 744 2067 if (exists $self->{'charset'})
27 153 2658 if (my $parts = $self->{'parts'}) { }
36 241 4 unless $_[1] eq "/"
44 3790 384 if $path =~ m[^/]u
47 367 17 unless $self->trailing_slash
53 600 7772 @_ > 1 ? :
66 797 12 $path =~ m[^/]u ? :
71 67 2 unless $clone->trailing_slash
77 27 1242 $clone->trailing_slash ? :
85 2003 1792 if (defined(my $path = $self->{'path'}))
86 2002 1 if $charset
92 1789 3 if $charset
94 1478 314 if $self->leading_slash
95 63 1729 if $self->trailing_slash
104 4661 10834 unless ($self->{'parts'})
107 4659 2 if $charset
113 13590 1905 unless @_