Condition Coverage

blib/lib/HTML/Form.pm
Criterion Covered Total %
condition 115 146 78.7


and 3 conditions

line !l l&&!r l&&r condition
71 30 1 2 ref $html and $html->can("content_charset")
118 57 8 1 exists $attr->{'id'} && exists $labels{$attr->{'id'}}
239 137 11 2 $type eq "file" and exists $attr->{'value'}
302 102 69 2 defined $no and $no < 1
310 2 2 3 defined $name and not $_->selected($name)
311 2 2 0 $type and $type ne $_->{'type'}
313 4 0 0 $no and $no != $c
322 13 156 418 defined $name and not $_->selected($name)
323 118 40 11 $type and $type ne $_->{'type'}
371 2 3 3 @v == 1 and ref $v[0]
485 7 0 0 $name and not $_->selected($name)
678 0 0 0 defined $_->{'name'} and length $_->{'name'}
0 0 0 defined $_->{'name'} and length $_->{'name'} and $_->{'name'} ne $opt
680 0 0 0 exists $self->{'current'} and $self->{'current'} == $i
711 18 4 2 $self->{'strict'} and $self->{'readonly'}
715 18 2 2 $self->{'strict'} and defined $n
20 0 2 $self->{'strict'} and defined $n and defined $new
2 1 1 $self->{'strict'} and defined $n and defined $new and length $new > $n
760 67 11 4 $type eq "radio" and delete $self->{'disabled'}
786 15 51 16 $type eq "option" and exists $self->{'multiple'}
806 17 23 11 $self->{'type'} eq "option" and not exists $self->{'current'}
847 9 20 50 defined $val and defined $_->{'value'}
29 31 19 defined $val and defined $_->{'value'} and $val eq $_->{'value'}
870 1 28 3 not defined $cur_ignorecase and $lc_val eq lc $_->{'name'}
892 6 19 7 $self->{'strict'} and $disabled
977 1 0 1 defined $name && length $name

or 2 conditions

line l !l condition
131 53 13 delete $attr->{'type'} || 'text'
135 2 0 delete $attr->{'type'} || 'submit'
216 19 29 shift() || 'GET'
218 14 34 shift() || 'application/x-www-form-urlencoded'
320 68 100 $no ||= 1
1013 0 13 $self->{'headers'} || []
1064 0 1 $self->{'keytype'} || 'rsa'

or 3 conditions

line l !l&&r !l&&!r condition
179 2 2 1 $tag eq "/form" or $tag eq "input"
4 0 1 $tag eq "/form" or $tag eq "input" or $tag eq "textarea"
2 0 1 $tag eq "/form" or $tag eq "input" or $tag eq "textarea" or $tag eq "select"
0 0 1 $tag eq "/form" or $tag eq "input" or $tag eq "textarea" or $tag eq "select" or $tag eq "keygen"
217 48 0 0 shift() || Carp::croak('No action defined')
363 0 135 51 not defined $n or $n ne $name
384 2 7 0 $err ||= $@
411 0 6 8 not defined $n or $seen{$n}++
764 2 9 71 $self->{'checked'} || $self->{'option_selected'}
787 3 3 10 $self->{'disabled'} ||= delete $self->{'option_disabled'}
817 10 4 28 $self->{'disabled'} || _menu_all_disabled(@{$$self{'menu'};})
847 51 1 8 defined $val || defined $_->{'value'}
19 8 52 defined $val and defined $_->{'value'} and $val eq $_->{'value'} or not defined $val || defined $_->{'value'}
857 14 7 20 not defined $cur or $disabled
926 4 1 2 $_->{'seen'} || $_->{'disabled'}
1020 0 1 13 $form->method ne "POST" or $form->enctype ne "multipart/form-data"
1033 2 0 11 defined $content or grep /^Content$/i, keys %headers
0 1 10 not defined $file or length $file == 0