Branch Coverage

blib/lib/HTML/FillInForm/Lite.pm
Criterion Covered Total %
branch 102 122 83.6


line true false branch
74 1 4 if (@_ == 1) { }
90 162 3 $_[0] =~ /(['"]) (.*) \1/msx ? :
93 20 2 $_[0] =~ /$SPACE $id = ($ATTR_VALUE)/msx ? :
96 14 45 $_[0] =~ /$SPACE $type = ($ATTR_VALUE)/msx ? :
99 104 0 $_[0] =~ /$SPACE $name = ($ATTR_VALUE)/msx ? :
102 27 26 $_[0] =~ /$SPACE $value = ($ATTR_VALUE)/msx ? :
121 63 54 if (ref $self and not @_)
141 18 36 if (ref $self)
143 30 63 ref $val eq 'HASH' ? :
149 0 31 unless defined $val
151 0 31 if ($opt eq 'ignore_fields' or $opt eq 'disable_fields') { }
0 31 elsif ($opt eq 'fill_password') { }
21 10 elsif ($opt eq 'target') { }
0 10 elsif ($opt eq 'escape') { }
3 7 elsif ($opt eq 'layer') { }
5 2 elsif ($opt eq 'decode_entity') { }
163 0 0 if ($val) { }
164 0 0 ref $val eq 'CODE' ? :
176 4 1 if ($val) { }
177 1 3 ref $val eq 'CODE' ? :
196 1 99 unless defined $src
197 1 98 unless defined $q
205 89 8 if (ref $src eq 'SCALAR') { }
0 8 elsif (ref $src eq 'ARRAY') { }
214 6 2 if ($is_fh or not ref $src) { }
215 6 0 unless ($is_fh)
216 1 5 unless open my $in, '<' . $context->{'layer'}, $src
238 21 69 if (defined $context->{'target'}) { }
245 11 11 defined $id && $context->{'target'} eq $id ? :
279 0 59 if ($context->{'ignore_types'}{$type})
283 9 50 unless my $values_ref = $context->_get_param(_get_name($tag))
286 5 45 if ($type eq 'checkbox' or $type eq 'radio') { }
289 0 5 if (not defined $value) { }
296 5 0 if (grep {$value eq $_;} @{$values_ref;}) { }
297 5 0 unless $tag =~ /$CHECKED/msx
308 17 28 unless $tag =~ s/$value = $ATTR_VALUE/value="$new_value"/msx
317 1 28 unless my $values_ref = $context->_get_param(_get_name($tag))
320 23 5 unless ($tag =~ /$MULTIPLE/mosx)
332 26 22 unless (defined $value)
342 31 17 if (grep {$value eq $_;} @{$values_ref;}) { }
343 29 2 unless $tag =~ /$SELECTED/mosx
356 3 13 unless my $values_ref = $context->_get_param(_get_name($tag))
367 0 104 if not defined $name or $context->{'ignore_fields'}{$name}
371 96 8 unless (defined $ref)
375 13 83 if ($context->{'utf8'})
377 5 5 unless utf8::is_utf8($datum)
382 91 13 @{$ref;} ? :
404 1 10 unless (%entity2char)
408 0 1 unless open my $data_in, '<', '/root/.cpan/build/HTML-FillInForm-Lite-1.14-IowmX7/blib/lib/HTML/FillInForm/Lite.pm'
410 0 1 unless eval scalar <$data_in>
413 1 10 unless $entity2char{$1}
438 94 3 if (not &Scalar::Util::blessed($ref)) { }
0 3 elsif ($ref->can('param')) { }
440 88 6 if ($type eq 'HASH') { }
1 5 elsif ($type eq 'ARRAY') { }
0 5 elsif ($type eq 'CODE') { }
444 80 3 defined $_ ? :
10 83 ref $_ eq 'ARRAY' ? :
474 5 77 unless my $value = $hash_ref->{$key}
492 2 13 unless my $method = ${$ref_to_object;}->can($key)
495 1 12 @values == 1 && !defined($values[0]) ? :