Branch Coverage

blib/lib/Math/Calc/Units/Convert/Metric.pm
Criterion Covered Total %
branch 21 26 80.7


line true false branch
64 224 68 defined $prefix ? :
82 150 562 if ($what =~ /$Math::Calc::Units::Convert::Metric::metric_prefix_test/) { }
91 3 2 if ($$options{'small'}) { }
101 32 101 if ($Math::Calc::Units::Convert::Metric::abbrev{$prefix} or $Math::Calc::Units::Convert::Metric::abbrev{lc $prefix}) { }
129 253 431 if (my $prefix = $self->get_prefix($string)) { }
143 5 0 if ($exact = $self->get_abbrev($char)) { }
0 0 elsif ($char ne lc $char and $lower = $self->get_abbrev(lc $char)) { }
167 24 626 unless my($mult_from, $base_from) = $self->demetric($from)
168 0 626 unless my($mult_to, $base_to) = $self->demetric($to)
171 153 473 unless defined $submult
183 12 35 if ($$options{'abbreviate'})
185 3 9 if ($name =~ /(\w+)\Q$stem\E$/)
187 3 0 if (defined $prefix)