Branch Coverage

blib/lib/MVC/Neaf/X/Files.pm
Criterion Covered Total %
branch 37 52 71.1


line true false branch
116 0 13 unless defined $options{'root'}
118 0 13 if ref $options{'root'}
122 0 13 if @extra
126 0 13 unless $options{'buffer'} =~ /^(\d+)$/
129 1 12 if ($options{'dir_index'})
137 13 0 unless defined $options{'description'}
143 1 12 if $preload
180 6 8 if (my $data = $self->{'cache_content'}{$file})
181 0 6 if ($data->[1] and $data->[1] < $time) { }
190 0 8 if $file =~ m[/\.\./]
192 8 0 unless $self->{'allow_dots'}
197 1 7 if (-d $xfile)
199 1 0 if $self->{'dir_index'}
203 1 6 unless ($ok)
216 6 0 if defined $2
221 5 1 $type && $type =~ qr/^text|^image|javascript/ ? :
224 1 5 if $disposition
228 5 1 if ($size < $bufsize)
230 2 3 if ($self->{'cache_ttl'})
267 0 1 unless opendir my $fd, "$self->{'root'}/$dir"
274 125 0 unless $self->{'allow_dots'}
277 1 122 -d "$self->{'root'}/$dir/$entry" ? :
288 0 7 unless $MVC::Neaf::X::Files::b->{'dir'} <=> $MVC::Neaf::X::Files::a->{'dir'}
291 1 0 if $updir eq "."
376 3 2 unless $name =~ /\.([a-z0-9]{1,4})$/
400 0 4 unless wantarray