Branch Coverage

blib/lib/Email/Address/XS.pm
Criterion Covered Total %
branch 80 90 88.8


line true false branch
257 21 111 if (scalar @args == 2 and defined $args[0]) { }
51 60 elsif (scalar @args == 4 and defined $args[0] and defined $args[2]) { }
23 37 elsif (scalar @args > 4) { }
258 18 3 if exists $hash_keys{$args[0]}
260 50 1 if exists $hash_keys{$args[0]} and exists $hash_keys{$args[2]}
266 91 41 if ($is_hash) { }
269 1 40 if scalar @args > 3
270 2 39 if scalar @args > 2
271 6 35 if scalar @args > 1
272 7 34 if scalar @args > 0
277 2 130 if (exists $args{'copy'})
278 2 0 if ($class->is_obj($args{'copy'})) { }
296 66 66 if (exists $args{'address'}) { }
303 0 132 if $invalid
331 5 5 if wantarray
332 4 1 @addresses ? :
333 2 3 if scalar @addresses != 1
334 1 4 unless defined $self->{'original'}
355 16 2 if (defined $string) { }
417 68 147 unless @args
418 0 147 if exists $self->{'invalid'}
434 106 75 unless @args
435 4 71 if exists $self->{'cached_address'}
436 0 75 if exists $self->{'invalid'}
451 94 72 unless @args
452 1 71 if exists $self->{'cached_address'}
453 0 72 if exists $self->{'invalid'}
477 97 52 if (@args) { }
478 0 97 if exists $self->{'invalid'}
479 92 5 if defined $args[0]
480 14 83 unless (defined $user and defined $host)
487 35 17 if exists $self->{'cached_address'}
491 93 21 if (defined $user and defined $host and length $user and length $host) { }
512 55 152 unless @args
513 0 152 if exists $self->{'invalid'}
514 121 31 unless defined $args[0]
519 17 16 if $_ eq '('
520 16 17 if $_ eq ')'
521 2 31 if $count < 0
523 5 26 if $count != 0
541 20 14 if defined $phrase and length $phrase
543 2 12 if defined $comment and length $comment
545 8 4 if defined $user and length $user
594 5 0 unless defined $STRINGIFY
597 0 0 unless defined $method