Branch Coverage

blib/lib/Treex/PML.pm
Criterion Covered Total %
branch 59 110 53.6


line true false branch
65 0 9 $^O eq 'MSWin32' ? :
169 82 0 if (ref $what) { }
171 82 0 if (defined $old) { }
172 0 82 unless defined $new
174 0 82 if (UNIVERSAL::can("Data::Dumper", "init_refaddr_format"))
181 82 63 ref $old->[$_] && defined $new->[$_] ? :
186 0 82 if $@
202 0 0 if $ar->[$n] eq $i
208 145 188 $_[0] =~ m[^\s*[[:alnum:]]+://] ? :
212 3 170 $uri->path =~ m[(/|^)\.\.($|/)] ? :
221 0 0 unless (_is_absolute($filename) or _is_updir($filename))
224 0 0 if -d $f
237 55 37 unless (_is_absolute($filename) or _is_updir($filename))
240 27 28 if (-f $f)
241 27 0 unless $all
246 18 47 $all || ref $opts && $opts->{'strict'} ? :
253 9 55 unless defined $Treex::PML::resourcePath
254 55 0 wantarray ? :
259 0 11 if (defined $Treex::PML::resourcePath and length $Treex::PML::resourcePath)
266 0 0 $Treex::PML::resourcePath ne '' ? :
272 0 0 unless defined $Treex::PML::resourcePath
283 117 0 builtin::blessed($url) && $url->isa('URI') && ($url->scheme || 'file') eq 'file' || $url =~ m[^file:/] ? :
287 0 0 if (_is_local($url)) { }
300 0 123 if $Treex::PML::Debug
303 5 118 if (_is_absolute($rel_uri)) { }
3 115 elsif (_is_updir($rel_uri)) { }
306 3 0 _is_url($base) ? :
310 115 0 if (_is_local($base_uri))
311 86 29 if (-f $abs_f) { }
0 29 elsif (not _is_url($base)) { }
312 0 86 if $Treex::PML::Debug
313 81 5 _is_url($base) ? :
315 0 0 if $Treex::PML::Debug
316 0 0 if -f $rel_f
319 27 2 if ($use_resources)
321 27 0 if ($res)
322 0 27 if $Treex::PML::Debug
326 0 2 if $Treex::PML::Debug
331 2 0 _is_local($base) ? :
338 0 20 if $Treex::PML::Debug
343 20 0 if (eval { do { require $file } } or $INC{$file})
348 20 0 if ($b) { }
351 0 0 if $@
360 11 0 @_ == @Treex::PML::BACKENDS ? :
0 11 wantarray ? :
374 0 0 @new == @imported ? :
0 0 wantarray ? :
380 11 44 $backend =~ /:/ ? :
0 55 $backend =~ /^([^:]+)Backend$/ ? :
11 44 $backend =~ /^Treex::PML::Backend::/ ? :
11 44 $backend =~ /:/ ? :
391 24 0 if (UNIVERSAL::can($try, "open_backend"))
396 24 0 if $b and UNIVERSAL::can($b, "test") and UNIVERSAL::can($b, "read")
404 11 0 if (UNIVERSAL::can($try, "open_backend"))
409 11 0 if $b and UNIVERSAL::can($b, "write")