Branch Coverage

blib/lib/HTML/FormBuilder/Field.pm
Criterion Covered Total %
branch 50 62 80.6


line true false branch
28 0 97 @args % 2 ? :
34 61 36 if ($data->{'input'} and ref $data->{'input'} ne 'ARRAY')
53 0 71 if $data->{'override_input_class'}
55 0 71 if ($stacked == 0)
64 71 0 if ($stacked == 1)
65 0 71 $data->{'class'} ? :
67 0 71 if ($data->{'type'} and $data->{'type'} eq 'hidden') { }
75 56 15 if (defined $data->{'label'})
82 1 55 if ($data->{'label'}{'tooltip'}) { }
89 54 1 $label_text ? :
96 61 10 if (defined $data->{'input'})
106 1 70 if (defined $data->{'comment'})
109 1 0 unless ($data->{'comment'}{'no_new_line'})
115 48 23 if (defined $data->{'error'})
120 1 47 ref $data->{'error'} eq 'ARRAY' ? :
129 61 10 if (defined $data->{'input'})
133 71 0 if ($stacked == 1)
164 0 76 if ($input_field->{'wrap_in_div_class'})
169 15 61 if (eval { do { $input_field->can('widget_html') } }) { }
7 54 elsif ($input_field->{'type'} and $input_field->{'type'} eq 'textarea') { }
53 1 elsif ($input_field->{'type'}) { }
178 28 25 if ($type =~ /^(?:text|password)$/i) { }
1 24 elsif ($type =~ /button|submit/) { }
184 1 52 $type =~ /button|submit/ ? :
188 1 52 if ($type =~ /button|submit/)
192 0 76 if ($wrap_input)
196 3 73 if ($heading)
198 0 3 if ($wrap_heading)
202 1 2 if ($input_field->{'type'} and $input_field->{'type'} =~ /radio|checkbox/i) { }
211 1 75 if ($trailing)
213 0 1 if ($wrap_trailing)