Branch Coverage

blib/lib/Event/RPC/Client.pm
Criterion Covered Total %
branch 72 102 70.5


line true false branch
89 42 45 unless defined $insecure_msg_fmt_ok
91 0 87 if ($server ne "" and $host eq "")
121 0 91 if $self->get_connected
131 61 30 if $self->get_message_format eq "Event::RPC::Message::Negotiate" and $self->get_insecure_msg_fmt_ok
135 7 84 if ($ssl)
137 0 7 if $@
141 7 84 if ($ssl) { }
0 84 elsif ($server eq 'unix/') { }
143 5 2 if ($self->get_ssl_ca_file or $self->get_ssl_ca_path) { }
165 0 7 $ssl_opts ? :
2 5 unless $sock = "IO::Socket::SSL"->new("Proto", "tcp", "PeerPort", $port, "PeerAddr", $server, "Type", 1, "Timeout", $timeout, @verify_opts, $ssl_opts ? %{$ssl_opts;} : ())
170 0 0 unless $sock = "IO::Socket::UNIX"->new("Type", 1, "Peer", $port)
177 0 84 unless $sock = "IO::Socket::INET"->new("Proto", "tcp", "PeerPort", $port, "PeerAddr", $server, "Type", 1, "Timeout", $timeout)
194 65 24 if $self->get_message_format eq "Event::RPC::Message::Negotiate"
200 10 79 if ($@)
208 7 72 if ($auth_user)
215 0 4 unless ($rc->{'ok'})
221 76 0 if (not $self->get_classes) { }
239 0 174 if ($server eq 'unix/') { }
240 0 0 unless $sock = "IO::Socket::UNIX"->new("Type", 1, "Peer", $port)
247 87 87 unless $sock = "IO::Socket::INET"->new("Proto", "tcp", "PeerPort", $port, "PeerAddr", $server, "Type", 1)
262 152 1 if $self->get_sock
278 0 7 if ($error_cb) { }
297 9 56 if ($@)
300 6 3 if ($self->get_insecure_msg_fmt_ok)
319 0 56 unless my $module = $modules_by_format_name->{$format}
324 56 0 unless ($@)
331 0 56 unless $format_chosen
340 0 56 if $@
351 7 79 if $@
356 0 79 if ($rc->{'version'} ne $self->get_client_version)
362 0 79 if ($rc->{'protocol'} < $self->get_client_protocol)
395 0 0 unless $classes{$class}
409 0 0 if $classes{$class}
420 0 152 if $loaded_classes->{$class}
432 131 34 unless $self->get_connected
447 228 1292 if ($method_type eq '_constructor') { }
836 456 elsif ($method_type eq '1') { }
474 0 248 unless $rc
476 1 247 if wantarray
492 0 71 unless $rc
496 1 71 if (ref $val eq 'ARRAY') { }
1 70 elsif (ref $val eq 'HASH') { }
69 1 elsif (defined $val) { }
500 0 10 unless $loaded_classes->{$class}
511 0 10 unless $loaded_classes->{$class}
521 0 69 unless $loaded_classes->{$class}
527 1 70 if wantarray
546 7 677 if ($@)
551 13 664 unless ($rc->{'ok'})
552 4 9 unless $rc->{'msg'} =~ /\n$/