Branch Coverage

lib/Sisimai/RFC5322.pm
Criterion Covered Total %
branch 61 68 89.7


line true false branch
36 1 1 if exists {"addresser" => ["from","return-path","reply-to","errors-to","reverse-path","x-postfix-sender","envelope-from","x-envelope-from"],"date" => ["date","posted-date","posted","resent-date"],"listid" => ["list-id"],"messageid" => ["message-id"],"recipient" => ["to","delivered-to","forward-path","envelope-to","x-envelope-to","resent-to","apparently-to"],"subject" => ["subject"]}->{$group}
51 1 4448 if ref $argv1
52 2 4446 if index($argv1, [" invoked by uid"," invoked from network"]->[0]) > 0 or index($argv1, [" invoked by uid"," invoked from network"]->[1]) > 0
77 0 78658 unless ++$index < $range
78 60261 18397 unless grep {$f eq $_;} @$label
84 14668 3718 unless $f eq "from"
85 5 3713 unless $index + 2 < $range
86 587 3126 unless index($$recvd[$index + 2], "(") == 0
106 0 3126 unless $index + 3 < $range
113 963 5289 if length $e < 4 or $e eq "unknown"
114 486 4447 if $e eq "localhost" or $e eq "[127.0.0.1]" or $e eq "[IPv6:::1]"
115 578 3869 if index($e, ".") == -1 or index($e, "=") > 1
121 874 8018 unless defined $token->{$e}
122 0 8018 unless length $token->{$e}
123 7788 230 unless index($token->{$e}, "[") == 0
130 382 4064 if $token->{'from'} eq "localhost" or $token->{'from'} eq "localhost.localdomain"
131 1181 2883 if index($token->{'from'}, ".") == -1
132 410 2473 if scalar @{"Sisimai::RFC791"->find($token->{'from'})}
140 2473 1973 if $right
141 1394 579 if scalar @$alter == 0
142 221 358 if index($alter->[0], $token->{'from'}) != -1
144 25 333 if (index($token->{'from'}, 'localhost') == 0) { }
80 253 elsif (index($token->{'from'}, '.') == -1) { }
150 80 0 if index($alter->[0], ".") > 0
159 146 4300 unless defined $token->{'by'}
160 0 4446 unless defined $token->{'from'}
161 2871 1575 if exists $token->{'for'}
164 0 19044 if index($token->{$e}, " ") != -1
198 2939 3437 if $positionor == -1
203 3392 1064 if ($positionor > 0) { }
214 3392 1064 if (length $latterpart > 0)
221 3374 18 if ($keeps == 0)
223 3374 0 if index $latterpart, "\n\n"
225 15 3377 unless substr($latterpart, -1, 1) eq "\n"