Branch Coverage

blib/lib/CGI/Application/Plugin/LogDispatch.pm
Criterion Covered Total %
branch 50 72 69.4


line true false branch
27 2 7 if @_
35 7 11 unless ($log)
37 0 7 unless $options
40 2 5 if ($$options{'LOG_DISPATCH_OPTIONS'}) { }
47 7 0 if ($$options{'LOG_DISPATCH_MODULES'}) { }
49 0 9 if (not $$logger{'module'}) { }
0 9 elsif (not $$logger{'module'}->require) { }
60 2 7 if ($$logger{'append_newline'} or $$options{'APPEND_NEWLINE'})
61 2 0 if exists $$logger{'append_newline'}
62 0 2 if $$logger{'callbacks'} and ref $$logger{'callbacks'} ne 'ARRAY'
77 0 0 if $$options{'APPEND_NEWLINE'}
83 0 7 if (UNIVERSAL::can($self, 'devpopup'))
106 5 2 ref $self ? :
109 5 2 if (ref $self) { }
110 0 5 if @_ and defined $$self{'__LOG_OBJECT'}
114 0 2 if @_ and defined ${$class . '::__LOG_OBJECT';}
119 7 0 if (@_)
121 0 7 if (ref $_[0] eq 'HASH') { }
129 2 5 if ($$props{'LOG_DISPATCH_OPTIONS'})
130 0 2 if ref $$props{'LOG_DISPATCH_OPTIONS'} ne 'HASH'
136 7 0 if ($$props{'LOG_DISPATCH_MODULES'})
137 0 7 if ref $$props{'LOG_DISPATCH_MODULES'} ne 'ARRAY'
143 0 7 if ($$props{'APPEND_NEWLINE'})
149 1 6 if ($$props{'LOG_METHOD_EXECUTION'})
150 0 1 if ref $$props{'LOG_METHOD_EXECUTION'} ne 'ARRAY'
157 0 7 if %$props
178 0 1 unless (eval { do { 'Sub::WrapPackages'->require; 'Sub::WrapPackages'->import('packages', [@_], 'pre', sub { $log->debug("calling $_[0](" . join(', ', @_[1 .. $#_]) . ')'); } , 'post', sub { BEGIN {${^WARNING_BITS} = "\020\001\000\000\000P\004\000\000\000\000\000\000U\025"} $log->debug("returning from $_[0] (" . join(', ', @_[1 .. $#_]) . ')'); } ); 1 } })
196 5 2 ref $self ? :
198 5 2 if (ref $self) { }
208 17 1 ref $self ? :
211 17 1 if (ref $self)
212 7 10 if $$self{'__LOG_OBJECT'}
213 5 5 if $$self{'__LOG_CONFIG'}
223 4 3 if ${$super . '::__LOG_OBJECT';}
224 2 1 if ${$super . '::__LOG_CONFIG';}
234 0 0 $r ? :