Branch Coverage

blib/lib/Food/Ratio.pm
Criterion Covered Total %
branch 48 48 100.0


line true false branch
34 2 18 unless defined $mass and &looks_like_number($mass) and $mass > 0
38 2 16 unless defined $name and length $name
40 2 14 unless defined $grname and length $grname
45 10 4 @rest ? :
51 6 8 unless defined $gmeta->[3]
58 1 1 unless defined $key
88 4 6 if (exists $param{'id'}) { }
4 2 elsif (exists $param{'group'}) { }
90 2 2 unless defined $param{'id'} and length $param{'id'}
95 1 8 if ($ref->[1] eq $param{'id'})
101 1 1 unless $okay
104 2 2 unless defined $param{'group'} and length $param{'group'}
105 1 1 unless exists $$groups{$param{'group'}}
119 1 4 unless defined $key
127 1 3 if (keys %$groups)
142 1 12 unless defined $key
143 2 9 unless defined $mass and &looks_like_number($mass) and $mass > 0
148 4 5 if (exists $param{'id'}) { }
4 1 elsif (exists $param{'group'}) { }
150 2 2 unless defined $param{'id'} and length $param{'id'}
155 1 7 if ($ref->[1] eq $param{'id'})
161 1 1 unless $okay
164 2 2 unless defined $param{'group'} and length $param{'group'}
165 1 1 unless exists $$groups{$param{'group'}}