Branch Coverage

blib/lib/Chemistry/FormulaPattern.pm
Criterion Covered Total %
branch 29 46 63.0


line true false branch
135 2 13 if ($string =~ s/\*//g)
148 5 11 if ($$self{'matched'} and $$self{'matched'} eq $mol)
160 9 6 if ($$have_formula{$symbol} >= $$want_formula{$symbol}{'low'} and $$have_formula{$symbol} <= $$want_formula{$symbol}{'high'}) { }
168 5 0 if ($good == @want_keys and $good == @have_keys || $$self{'options'}{'allow_others'})
196 0 15 unless ParensBalanced($formula)
211 0 15 if ($formula =~ s/^(\d+)(-?)(\d*)//)
213 0 0 if ($is_range) { }
214 0 0 unless length $high
231 2 15 if (defined $extract and $extract ne '') { }
233 2 0 if ($remainder =~ s/^(\d+)(-?)(\d*)//) { }
235 2 0 if ($tmp_is_range) { }
236 0 2 unless length $tmp_high
248 0 2 if $prefix ne ''
251 0 2 if $remainder ne ''
259 15 0 if $remainder ne ''
269 0 15 unless $formula =~ /^(?:([A-Z][a-z]*)(\d+-?\d*)?)+$/o
273 15 18 unless defined $low
274 10 23 if ($is_range) { }
275 3 7 unless length $high
297 2 2 if ($current =~ /[<({\[]/)
301 0 2 if scalar @stack == 0
302 0 2 if $current ne $pairs{pop @stack}
304 0 15 @stack ? :