Branch Coverage

blib/lib/Mail/SpamAssassin/Plugin/Pyzor.pm
Criterion Covered Total %
branch 2 80 2.5


line true false branch
58 62 1 if ($mailsaobject->{'local_tests_only'}) { }
163 0 0 unless ($value =~ m[^([0-9A-Za-z ,._/-]+)$])
186 0 0 unless (defined $value and length $value)
190 0 0 unless (-x $value)
206 0 0 unless ($pyzor)
209 0 0 unless ($pyzor and -x $pyzor)
224 0 0 if (not $self->{'main'}{'conf'}{'use_pyzor'}) { }
0 0 elsif ($self->is_pyzor_available) { }
248 0 0 unless $self->{'pyzor_available'}
283 0 0 unless $pid
288 0 0 unless defined $nread
291 0 0 unless close PYZOR
292 0 0 if (proc_status_ok($?, $errno)) { }
0 0 elsif (proc_status_ok($?, $errno, 0, 1)) { }
300 0 0 unless (@response)
307 0 0 if ($response[0] =~ /^Traceback/)
313 0 0 if (defined fileno PYZOR)
314 0 0 if ($pid)
315 0 0 if (kill 'TERM', $pid) { }
318 0 0 unless close PYZOR
319 0 0 unless proc_status_ok($?, $errno)
324 0 0 if ($timer->timed_out)
329 0 0 if ($err)
331 0 0 if ($err eq '__brokenpipe__ignore__') { }
0 0 elsif ($err eq 'no response') { }
343 0 0 if ($one_response =~ /^\S+\t.*?\t(\d+)\t(\d+)\s*$/) { }
355 0 0 $pyzor_whitelisted ? :
358 0 0 if ($pyzor_count >= $self->{'main'}{'conf'}{'pyzor_max'})
369 0 0 unless $self->{'pyzor_available'}
370 0 0 unless $self->{'main'}{'conf'}{'use_pyzor'}
372 0 0 if (not $options->{'report'}{'options'}{'dont_report_to_pyzor'} and $self->is_pyzor_available)
376 0 0 if ($self->pyzor_report($options, $tmpf)) { }
408 0 0 unless $pid
413 0 0 unless defined $nread
415 0 0 if $nread_all < 1
417 0 0 unless close PYZOR
421 0 0 if (proc_status_ok($?, $errno, 0)) { }
431 0 0 if ($timer->timed_out)
436 0 0 if ($err)
438 0 0 if ($err eq '__brokenpipe__ignore__') { }