Branch Coverage

blib/lib/Text/FixedWidth.pm
Criterion Covered Total %
branch 48 66 72.7


line true false branch
85 0 5 unless (@att % 3 == 0)
88 0 14 if (exists $$self{'_attributes'}{$att})
91 8 6 if ($value and $value eq 'undef')
148 0 7 unless ($att)
151 0 7 unless ($sprintf or $reader)
154 0 7 if ($reader and not defined $length)
157 0 7 if (exists $$self{'_attributes'}{$att})
161 0 7 if ($value and $value eq 'undef')
163 4 3 if ($sprintf) { }
188 0 11 unless $args{'string'}
191 10 1 if $args{'clone'}
200 10 1 $args{'clone'} ? :
241 3 38 if ($reader)
243 0 3 if (length $rval != $length)
249 0 38 if (defined $value and length $value > $length)
253 10 28 unless (defined $value)
256 0 38 unless ($sprintf)
262 3 6 if ($sprintf =~ /\%\d*[duoxefgXEGbB]/ and !defined($value) || $value eq '' || !($value =~ /^(\d+\.?\d*|\.\d+)$/))
269 0 3 unless defined $value
273 38 0 defined $value ? :
275 0 38 if (length $rval != $length)
299 1 2 unless ($$self{'_attributes'}{$attr})
342 17 23 if ($Text::FixedWidth::AUTOLOAD =~ /.*::get_(\w+)/)
350 13 10 if ($Text::FixedWidth::AUTOLOAD =~ /.*::getf_(\w+)/)
358 10 0 if ($Text::FixedWidth::AUTOLOAD =~ /.*::set_(\w+)/)
372 0 55 unless defined $$self{'_attributes'}{$att}
374 33 22 if $ret
375 33 22 if $ret
386 0 17 unless defined $$self{'_attributes'}{$att}
387 17 0 if (defined $$self{'_attributes'}{$att}) { }
388 3 14 if ($writer) { }
3 14 elsif (defined $val and length $val > $length) { }
391 2 1 if ($$self{'_auto_truncate'}{$att}) { }