Condition Coverage

blib/lib/Mail/SpamAssassin/HTML.pm
Criterion Covered Total %
condition 82 155 52.9


and 3 conditions

line !l l&&!r l&&r condition
108 7 0 0 $character_semantics_input && !$character_semantics_output
168 0 0 7 exists $self->{'elements'} and exists $self->{'tags'}
172 0 0 7 exists $self->{'elements_seen'} and exists $self->{'tags_seen'}
177 0 7 0 exists $self->{'tags'} and exists $self->{'obfuscation'}
274 6 1 0 exists $self->{'inside'}{'style'} and $self->{'inside'}{'style'} > 0
275 7 0 0 exists $self->{'inside'}{'script'} and $self->{'inside'}{'script'} > 0
424 0 0 0 @{$self->{'text_style'};} and $top = $self->{'text_style'}[-1]{'tag'}
425 0 0 0 $tag eq 'td' and $top eq 'font' || $top eq 'td'
0 0 0 $tag eq 'tr' and $top =~ /^(?:font|td|tr)$/
463 304 0 0 $tag eq 'basefont' and exists $attr->{'size'}
0 0 0 $tag eq 'basefont' and exists $attr->{'size'} and $attr->{'size'} =~ /^\s*(\d+)/
612 215 0 0 $display and lc $display eq 'none'
616 215 0 0 $visibility and lc $visibility eq 'hidden'
626 349 81 34 $tag eq 'font' and exists $attr->{'face'}
640 457 5 2 $tag eq 'img' and exists $self->{'inside'}{'a'}
5 1 1 $tag eq 'img' and exists $self->{'inside'}{'a'} and $self->{'inside'}{'a'} > 0
647 457 0 7 $tag eq 'img' and exists $attr->{'width'}
0 0 7 $tag eq 'img' and exists $attr->{'width'} and exists $attr->{'height'}
655 0 0 0 defined $2 and $2 eq '%'
659 0 0 0 defined $2 and $2 eq '%'
664 0 0 7 $width > 0 and $height > 0
669 464 0 0 $tag eq 'form' and exists $attr->{'action'}
689 462 0 2 $tag eq 'meta' and exists $attr->{'http-equiv'}
0 0 2 $tag eq 'meta' and exists $attr->{'http-equiv'} and exists $attr->{'content'}
0 1 1 $tag eq 'meta' and exists $attr->{'http-equiv'} and exists $attr->{'content'} and $attr->{'http-equiv'} =~ /Content-Type/i
1 0 1 $tag eq 'meta' and exists $attr->{'http-equiv'} and exists $attr->{'content'} and $attr->{'http-equiv'} =~ /Content-Type/i and $attr->{'content'} =~ /\bcharset\s*=\s*["']?([^"']+)/i
712 6 179 17 defined $self->{'text_whitespace'} && vec($self->{'text_whitespace'}, $#{$$self{'text'};}, 1)
0 17 185 @{$self->{'text'};} and not defined $self->{'text_whitespace'} && vec($self->{'text_whitespace'}, $#{$$self{'text'};}, 1)
0 185 0 defined $self->{'text_invisible'} && vec($self->{'text_invisible'}, $#{$$self{'text'};}, 1)
17 0 185 @{$self->{'text'};} and not defined $self->{'text_whitespace'} && vec($self->{'text_whitespace'}, $#{$$self{'text'};}, 1) and not defined $self->{'text_invisible'} && vec($self->{'text_invisible'}, $#{$$self{'text'};}, 1)
726 7 0 477 @{$self->{'text'};} and not $display{'invisible'}
7 184 293 @{$self->{'text'};} and not $display{'invisible'} and defined $self->{'text_whitespace'}
184 108 185 @{$self->{'text'};} and not $display{'invisible'} and defined $self->{'text_whitespace'} and vec $self->{'text_whitespace'}, $#{$$self{'text'};}, 1
746 485 0 0 exists $self->{'inside'}{'script'} and $self->{'inside'}{'script'} > 0
751 418 66 1 exists $self->{'inside'}{'style'} and $self->{'inside'}{'style'} > 0
756 93 274 117 exists $self->{'inside'}{'a'} and $self->{'inside'}{'a'} > 0
763 416 67 1 exists $self->{'inside'}{'title'} and $self->{'inside'}{'title'} > 0
782 330 147 0 $text =~ /^[^\s\x21-\x2f\x3a-\x40\x5b-\x60\x7b-\x7e]/s and $self->{'text'}[-1] =~ /[^\s\x21-\x2f\x3a-\x40\x5b-\x60\x7b-\x7e]\z/s
1065 3 96 0 length $color > 3 and length $color < 6
1142 58 34 0 defined $base_authority and not $base_path
1163 98 73 2 defined $r{'scheme'} and defined $base{'scheme'}
171 1 1 defined $r{'scheme'} and defined $base{'scheme'} and $r{'scheme'} eq $base{'scheme'}

or 2 conditions

line l !l condition
345 0 131 $self->{'base_href'} || ''

or 3 conditions

line l !l&&r !l&&!r condition
288 824 0 0 exists $elements{$tag} or $maybe_namespace
303 824 0 0 exists $elements{$tag} or exists $tricks{$tag}
326 91 2 109 $tag eq 'br' or $tag eq 'div'
425 0 0 0 $top eq 'font' || $top eq 'td'
0 0 0 $tag eq 'td' and $top eq 'font' || $top eq 'td' or $tag eq 'tr' and $top =~ /^(?:font|td|tr)$/
471 8 7 289 $tag eq 'td' or $tag eq 'tr'
494 0 90 154 $name eq 'text' or $name eq 'color'
601 0 0 215 $fg eq 'invalid' or $bg eq 'invalid'
672 0 0 464 $tag eq 'object' or $tag eq 'embed'