Branch Coverage

blib/lib/Net/Connection/Match/Ports.pm
Criterion Covered Total %
branch 17 44 38.6


line true false branch
92 3 1 if (defined $_[1])
97 1 0 unless (defined $args{'ports'} or defined $args{'fports'} or defined $args{'lports'})
104 0 0 if (defined $args{'ports'} and not defined $args{'ports'}[0] and (defined $args{'lports'} and not defined $args{'lports'}[0]) and (defined $args{'fports'} and not defined $args{'fports'}[0]))
130 3 0 if (defined $args{'ports'})
132 3 0 if ($args{'ports'}[$ports_int] =~ /^[0-9]+$/) { }
0 0 elsif ($args{'ports'}[$ports_int] =~ /^\*$/) { }
139 0 0 unless (defined $port_number)
152 3 0 if (defined $args{'lports'})
154 3 0 if ($args{'lports'}[$ports_int] =~ /^[0-9]+$/) { }
0 0 elsif ($args{'lports'}[$ports_int] =~ /^\*$/) { }
161 0 0 unless (defined $port_number)
174 3 0 if (defined $args{'fports'})
176 3 0 if ($args{'fports'}[$ports_int] =~ /^[0-9]+$/) { }
0 0 elsif ($args{'fports'}[$ports_int] =~ /^\*$/) { }
183 0 0 unless (defined $port_number)
215 1 7 unless (defined $object)
219 1 6 if (ref $object ne 'Net::Connection')
227 0 6 unless ($lport =~ /^[0-9]+$/)
229 0 0 if (defined $lport_number)
233 0 6 unless ($fport =~ /^[0-9]+$/)
235 0 0 if (defined $fport_number)
241 1 1 if (defined $self->{'ports'}{$lport} or defined $self->{'ports'}{$fport} or defined $self->{'lports'}{$lport} or defined $self->{'fports'}{$fport})