Branch Coverage

blib/lib/Resource/Silo/Metadata.pm
Criterion Covered Total %
branch 82 86 95.3


line true false branch
74 37 63 if (@_ % 2)
81 4 95 unless defined $name and not ref $name and $name =~ /$ID_REX/i
84 1 94 if defined $self->{'resource'}{$name}
85 2 92 if $target->can($name)
89 1 91 if @extra
94 86 5 unless (ref $spec{'require'})
95 3 83 defined $spec{'require'} ? :
98 1 90 unless ref $spec{'require'} eq "ARRAY"
101 1 89 if @bad
105 4 85 if (defined(my $value = $spec{'literal'}))
116 8 79 if defined $spec{'class'}
118 14 67 if (my $deps = delete $spec{'dependencies'})
119 1 13 unless ref $deps eq "ARRAY"
123 2 11 if @bad
128 73 5 unless ($spec{'loose_deps'})
131 9 64 if defined $spec{'argument'}
133 8 65 if ($spec{'allowdeps'}) { }
136 1 7 if @fwd
147 3 74 unless ref $spec{'init'} and &reftype($spec{'init'}) eq $CODE
149 65 9 if (not defined $spec{'argument'}) { }
6 3 elsif (ref $spec{'argument'} eq $REGEXP) { }
2 1 elsif ((&reftype($spec{'argument'}) // '') eq $CODE) { }
164 1 72 unless &looks_like_number($spec{'cleanup_order'})
170 1 1 if $spec{'ignore_cache'} and defined $spec{'cleanup'} || defined $spec{'fork_cleanup'} || $spec{'cleanup_order'} != 0
174 2 68 if defined $spec{'cleanup'} and (&reftype($spec{'cleanup'}) // "") ne $CODE
176 2 66 if defined $spec{'fork_cleanup'} and (&reftype($spec{'fork_cleanup'}) // "") ne $CODE
178 1 65 if ($spec{'preload'})
203 1 7 unless $class =~ /$MOD_REX/
208 1 5 unless ref $spec->{'dependencies'} eq "HASH"
222 1 6 if (ref $entry eq "SCALAR")
228 1 5 if (defined $entry and not ref $entry)
230 1 0 if $entry eq 1
233 2 3 unless ref $entry eq "ARRAY" and @$entry <= 2 and ($entry->[0] // "") =~ /$ID_REX/
241 1 2 length($entry->[1] // '') ? :
246 1 1 if %pass_args
258 1 1 %pass_args ? :
281 5 1 wantarray ? :
297 1 5 unless $spec
302 5 0 if (my $deps = delete $show{'allowdeps'})
306 5 0 if (exists $show{'orig_argument'})
338 0 10 unless $entry->{'allowdeps'}
340 2 8 if @missing_deps
344 1 1 unless eval { do { &load($mod); 1 } }