Condition Coverage

blib/lib/Net/IP/Lite.pm
Criterion Covered Total %
condition 82 88 93.1


and 3 conditions

line !l l&&!r l&&r condition
49 1737 633 230 $addr =~ s/^:// and not $addr =~ /^:/
50 1947 282 141 $addr =~ s/:$// and not $addr =~ /:$/
115 14623 4622 336 $i == scalar @octets and $i < 4
222 20 20 8 $format eq 'X' and $lead_zeros
239 142 50 260 not $octet and $i
192 50 210 not $octet and $i and $i < 3
270 644 24 36 $convert_to eq 'ipv4' and _ip_is_ipv6ipv4($bin)
275 524 44 136 $convert_to eq 'ipv6' || $convert_to eq 'ipv6ipv4' and _ip_is_ipv4($bin)
280 612 12 80 $convert_to eq 'ipv6ipv4' and _ip_is_ipv6ipv4($bin)
353 33 7 11 _ip_is_ipv6($bin1) and not _ip_is_ipv6ipv4($bin1)
357 23 8 9 _ip_is_ipv6($bin2) and not _ip_is_ipv6ipv4($bin2)
421 126 74 1894 _ip_validate($bin_net) and _ip_validate($bin_mask)
200 6 1888 _ip_validate($bin_net) and _ip_validate($bin_mask) and _ip_type_equal($bin_net, $bin_mask)
504 94 0 31 blessed $addr and $addr->isa('Net::IP::Lite')
517 116 0 31 blessed $addr && $addr->isa('Net::IP::Lite')
520 57 14 13 $self->is_ipv6 and not $self->is_ipv6ipv4
524 46 16 9 _ip_is_ipv6($bin2) and not _ip_is_ipv6ipv4($bin2)
534 101 0 38 blessed $addr && $addr->isa('Net::IP::Lite')
553 1169 0 414 blessed $range and $range->isa('Net::IP::Lite::Net')
603 289 1 712 $self->is_ipv4 and $ipv4_mask
1 2 287 $self->is_ipv6 and not $ipv4_mask
622 414 0 414 blessed $addr and $addr->isa('Net::IP::Lite')

or 2 conditions

line l !l condition
210 176 554 $format ||= ''
264 256 448 $$opts{'format_ipv4'} || ''
265 240 464 $$opts{'convert_to'} || ''
314 328 88 $opts ||= {}
496 328 25 $opts ||= {}

or 3 conditions

line l !l&&r !l&&!r condition
64 40 60 218 $i != scalar @words or $bin ne '000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111'
68 20 20 752 not $octet =~ /^\d+$/ or $octet > 255
275 88 92 524 $convert_to eq 'ipv6' || $convert_to eq 'ipv6ipv4'
603 712 0 290 $self->is_ipv4 and $ipv4_mask or $self->is_ipv6 and not $ipv4_mask