Branch Coverage

blib/lib/OpenTelemetry/Instrumentation/namespace.pm
Criterion Covered Total %
branch 38 60 63.3


line true false branch
29 1 2 unless @$rules
33 46 599 if (lc $module eq $module)
38 0 599 if ($module =~ /^[0-9]/u)
57 6 69 if $old_hook
60 6 69 if ref $return and is_coderef($return)
61 0 75 unless $INC{$name}
77 4 1 unless ($_->[0] =~ /^-/u)
85 1 4 if (my $path = delete $options{'-from_file'})
89 1 0 is_hashref($loaded) ? :
105 0 674 if ($package =~ /^::/u)
110 38 636 if ($package =~ /^OpenTelemetry/u)
116 281 355 if ($package =~ /^(?:B|Exporter|Test2|Plack|XSLoader)(?:::|$)/u)
121 0 355 if (my $instrumentation = $class->for_package($package))
122 0 0 if ($options->{'-prefer_instrumentations'})
131 0 0 if ($INC{$notional})
149 383 326 is_regexpref($matcher) ? :
705 4 if is_regexpref($matcher) ? !($package =~ /$matcher/u) : $package ne $matcher
155 1 3 unless $rules
165 3 2 unless ref $rules
166 0 5 if is_hashref($rules)
175 0 0 if ($subname =~ /^(?:un)?import$/u and $options->{'-ignore_import'})
182 0 0 if (uc $subname eq $subname and $options->{'-ignore_constants'})
189 0 0 if ($subname =~ /^_/u and $options->{'-ignore_private'})
198 10 0 if (my $gv = Devel::Peek::CvGV($coderef))
199 0 10 if (*$gv{"PACKAGE"} ne $package)
207 0 10 if (defined prototype $coderef)
217 4 9 unless $subname =~ /$matcher/u
218 0 9 unless $spanner
221 0 9 if ($CACHE{$package}{$subname}++)
240 9 0 unless is_coderef($spanner)