Branch Coverage

blib/lib/Test/Expander.pm
Criterion Covered Total %
branch 97 98 100.0


line true false branch
43 2 1 eval { do { qr/$opt_value/ } } ? :
47 1 2 unless $opt_value =~ m[^ \d+ (?: / \d+ )* $]x
51 1 24 if $error
100 1 18 if defined $CLASS and exists $options->{'-builtins'}
120 1 4 if $@
152 11 1 $expected_type eq 'Regexp' ? :
176 3 20 if ($options->{'-lib'})
178 1 2 if ref $directory
180 1 1 if $@
186 4 17 if (exists $options->{'-method'}) { }
193 15 6 unless (exists $options->{'-target'})
196 14 1 if grep {path($_)->child($testee . ".pm")->is_file;} @INC
198 17 4 if (defined $options->{'-target'}) { }
211 4 3 if $@ eq ""
214 1 2 if defined $search_string
221 21 1 if path($test_file)->exists
228 15 4 if $CLASS and $METHOD and $METHOD_REF = $CLASS->can($METHOD)
239 39 73 unless my $value = eval "${\$name;}"
264 1 3 $@ ? :
272 2 24 unless $option_name =~ /^-\w/
275 3 21 if ($option_name eq '-builtins') { }
4 17 elsif ($option_name eq '-lib') { }
5 12 elsif ($option_name eq '-method') { }
6 6 elsif ($option_name eq '-target') { }
3 3 elsif ($option_name eq '-tempdir') { }
2 1 elsif ($option_name eq '-tempfile') { }
276 1 2 if ref $option_value ne "HASH"
278 1 1 if ref $sub_ref ne "CODE"
283 1 3 if ref $option_value ne "ARRAY"
287 1 4 if ref $option_value
294 1 2 if ref $option_value ne "HASH"
298 1 1 if ref $option_value ne "HASH"
317 1 13 unless $line =~ /^ (? \w+) \s* (?: = \s* (? \S .*) | $ )/x
319 11 2 if (exists $+{'value'}) { }
1 1 elsif (exists $ENV{$+{'name'}}) { }
328 0 11 if $@
330 2 9 if $@
333 2 9 if $@
334 8 1 if (defined $value) { }
354 1 29 unless path($test_file)->exists
365 7 22 if (path($env_file)->is_file)
366 6 1 unless $env_found
371 5 22 if $env_found
379 27 48 unless $class
384 2 46 unless path($class_top_level)->is_dir
387 2 44 if (path($env_file)->is_file)
388 1 1 unless $env_found
401 14 1 if (not @subtest_names || @subtest_numbers or grep {$name =~ /$_/;} @subtest_names or grep {/^$number/;} @subtest_numbers) { }
420 1 3 @$imports == 1 && $imports->[0] =~ /$Test::Expander::REGEX_VERSION_NUMBER/ ? :