Branch Coverage

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


line true false branch
14 12 1374 if (not length $parts->[$i] or $parts->[$i] eq '.' or $parts->[$i] eq '...') { }
1356 18 elsif ($i < 1 or $parts->[$i] ne '..' or $$parts[$i - 1] eq '..') { }
19 847 85 @$parts ? :
26 698 1933 if (exists $self->{'charset'})
27 152 2479 if (my $parts = $self->{'parts'}) { }
36 242 4 unless $_[1] eq "/"
44 3564 353 if $path =~ m[^/]u
47 337 16 unless $self->trailing_slash
53 563 7319 @_ > 1 ? :
66 809 12 $path =~ m[^/]u ? :
71 67 2 unless $clone->trailing_slash
77 27 1171 $clone->trailing_slash ? :
85 1935 1757 if (defined(my $path = $self->{'path'}))
86 1934 1 if $charset
92 1754 3 if $charset
94 1447 310 if $self->leading_slash
95 63 1694 if $self->trailing_slash
104 4424 10441 unless ($self->{'parts'})
107 4422 2 if $charset
113 13026 1839 unless @_