Branch Coverage

blib/lib/POE/Component/Client/NSCA.pm
Criterion Covered Total %
branch 28 66 42.4


line true false branch
119 0 4 unless $params{'host'}
121 0 4 unless $params{'event'}
123 0 4 unless $params{'password'} or $params{'encryption'} eq 1
125 0 4 unless defined $params{'encryption'}
127 0 4 unless $params{'message'} and ref $params{'message'} eq 'HASH'
130 0 12 unless defined $params{'message'}{$item}
133 0 4 unless defined $params{'port'}
134 4 0 unless defined $params{'timeout'} and $params{'timeout'} =~ /^\d+$/
137 0 4 ref $options eq 'HASH' ? :
151 0 4 if ($kernel == $sender and not $self->{'session'})
155 0 4 if ($self->{'session'}) { }
156 0 0 if (my $ref = $kernel->alias_resolve($self->{'session'})) { }
226 0 2 unless (length $input == 132)
246 0 2 unless ($data_packet_string_crypt)
268 0 4 if ($type eq 'badinit')
272 0 4 if ($type eq 'badencrypt')
276 2 2 if ($type eq 'sockerr')
280 0 2 if ($type eq 'timeout')
296 4 0 unless defined $message->{'svc_description'}
297 0 4 if (length $message->{'host_name'} >= 64)
301 0 4 if (length $message->{'svc_description'} >= 128)
305 0 4 if (length $message->{'plugin_output'} >= 512)
336 2048 2048 if ($crc & 1) { }
352 1 1 if ($encryption_method == 0) { }
1 0 elsif ($encryption_method == 1) { }
381 1 0 if ($password)
400 0 0 if ($HAVE_MCRYPT)
402 0 0 if (defined $mcrypts{$encryption_method})
410 0 0 if (defined $td)
419 0 0 if $@
425 0 0 if (not $evalok || defined $crypted and defined $encryption_method)
426 0 0 if (defined $mcrypts{$encryption_method} and !1)
428 0 0 unless ($routine =~ /_$/)