Branch Coverage

blib/lib/Log/Contextual.pm
Criterion Covered Total %
branch 25 38 65.7


line true false branch
19 0 0 unless ref $coderef
21 0 0 unless $cv->isa('B::CV')
24 0 0 if $cv->GV->isa('B::SPECIAL')
36 0 393 if (my $code = $target->can($name)) { }
39 0 0 unless stash_name($code) eq 'Log::Contextual'
78 26 1 unless $_[1]
93 6 26 if $spec->config->{'default'}
96 0 5 unless $_ =~ /^:(.*)$/
104 17 12 if ($exports->{'&set_logger'})
105 0 17 unless $router->does('Log::Contextual::Role::Router::SetLogger')
113 10 19 if ($exports->{'&with_logger'})
114 0 10 unless $router->does('Log::Contextual::Role::Router::WithLogger')
122 1 28 if ($exports->{'&has_logger'})
123 0 1 unless $router->does('Log::Contextual::Role::Router::HasLogger')
136 146 17 if ($spec->config->{'log'} or $$exports{"&log_$level"})
148 145 18 if ($spec->config->{'log'} or $$exports{"&logS_$level"})
160 37 126 if ($spec->config->{'dlog'} or $$exports{"&Dlog_$level"})
164 18 7 @_ ? :
176 37 126 if ($spec->config->{'dlog'} or $$exports{"&DlogS_$level"})