Branch Coverage

blib/lib/Mail/Message/Head/Complete.pm
Criterion Covered Total %
branch 54 108 50.0


line true false branch
41 0 25 unless defined $name
43 0 25 if ($name->isa('Mail::Message::Field'))
49 0 25 unless defined $content
51 0 25 if (ref $content and $content->isa('Mail::Message::Field'))
88 0 176 @_ == 1 && ref $_[0] ? :
90 0 176 unless defined $field
101 3 173 if (defined $known->{$name}) { }
102 1 2 if (ref $known->{$name} eq 'ARRAY') { }
118 0 0 ref $value ? :
0 0 !defined($value) ? :
130 0 6 ref $_ eq 'ARRAY' ? :
132 49 6 unless @take
135 6 0 if (@take == 1 and ref $take[0] eq 'Regexp') { }
159 442 12 @_ == 1 && ref $_[0] ? :
167 289 165 if ($skip_none{$name} and $field->body eq 'none')
185 7 1 if (@_ == 0)
186 1 6 if delete $known->{$name}
197 0 1 if (@_ == 1) { }
213 0 8 if (not defined $known->{$name}) { }
2 6 elsif (ref $known->{$name} eq 'ARRAY') { }
6 0 elsif ($known->{$name} eq $field) { }
219 2 0 if $known->{$name}[$i] eq $field
267 0 0 unless my(@sgs) = $self->spamGroups
279 0 35 if (ref $fh eq 'GLOB') { }
292 0 0 if (ref $fh eq 'GLOB') { }
308 0 0 ref $pattern ? :
309 0 0 if $found
312 0 0 if (not $found) { }
0 0 elsif (ref $fh eq 'GLOB') { }
328 0 6 wantarray ? :
343 2 1 @_ == 1 ? :
351 0 13 unless defined $order->[$i]
352 1 12 if $rg->isResentGroupFieldName($order->[$i]->name)
365 13 2 if (not defined $known->{$name}) { }
0 2 elsif (ref $known->{$name} eq 'ARRAY') { }
395 0 0 @_ ? :
397 0 0 wantarray || @_ != 1 ? :
409 0 2 unless (shift())->guessTimestamp
415 1 1 if exists $self->{'MMH_recvstamp'}
418 1 0 unless my $recvd = $self->get('received', 0)
422 0 0 defined $stamp && $stamp > 0 ? :
428 1 1 if exists $self->{'MMH_timestamp'}
431 1 0 if (my $date = $self->get('date'))
435 0 1 unless ($stamp)
438 0 0 if $stamp
442 1 0 defined $stamp && $stamp > 0 ? :
449 0 12 if defined $cl and $cl =~ /(\d+)/
452 0 12 if defined $lines and $lines =~ /(\d+)/
464 0 0 defined $sender ? :
479 0 10 unless @_ or not defined $msgid_creator
482 0 10 if @_ == 1 and ref $_[0] eq 'CODE'
488 10 0 unless (defined $hostname)
490 10 0 unless $@
495 10 0 if ('Time::HiRes'->can('gettimeofday'))