Branch Coverage

blib/lib/Business/Barcode/EAN13.pm
Criterion Covered Total %
branch 29 32 90.6


line true false branch
47 14 103 $prefix =~ /\.\.|,/ ? :
65 1 2 unless (_valid_stem($stem))
70 0 2 unless _valid_stem($stem)
90 1 20 $mod == 10 ? :
110 8 19 unless _valid_stem($bcode)
136 0 4 unless %prefix
139 3 298 if my(@match) = grep({$bcode =~ /^$_/;} @{$prefix{$_};})
173 1 9 unless %prefix
174 7 6 unless $prefix{$_}
179 13 9 unless (valid_barcode($barcode))
180 4 9 if length $barcode < 13
185 1 8 unless @prefs
187 3 7 unless $barcode =~ /^$prefs[$pref]/
188 5 2 if $pref == 0
204 3 1 unless ($best)
207 3 0 unless valid_barcode($barcode)