Branch Coverage

blib/lib/Net/PcapWriter/IP.pm
Criterion Covered Total %
branch 20 32 62.5


line true false branch
22 0 7 unless eval { do { "Socket"->import("inet_pton"); inet_pton(2, "127.0.0.1"); inet_pton(10, "::1"); 1 } } or eval { do { require Socket6; "Socket6"->import("inet_pton"); inet_pton(2, "127.0.0.1"); inet_pton(10, "::1"); 1 } }
35 3 4 defined $data ? :
47 3 4 if (defined $data)
48 0 3 unless $do_chksum
49 3 0 if (defined $chksum_offset)
50 3 0 $no_pseudo_header ? :
62 0 4 unless ($do_chksum)
69 0 4 unless (defined $chksum_offset)
78 0 10 $no_pseudo_header ? :
93 3 4 defined $data ? :
102 3 4 if (defined $data)
104 3 0 if ($do_chksum and defined $chksum_offset)
115 0 4 unless (defined $chksum_offset)
124 10 0 if ($do_chksum)
136 4 4 if $_[1] =~ /:/
142 0 0 if length($data) % 2