Branch Coverage

blib/lib/Lingua/TokenParse.pm
Criterion Covered Total %
branch 62 120 51.6


line true false branch
53 0 2 if $self->{'verbose'}
54 1 1 if $self->{'word'}
63 1 1 if $self->{'lexicon_file'}
68 0 0 if @_
75 0 1 if $self->{'verbose'}
76 1 0 if (@_)
81 0 1 if $self->{'verbose'}
88 2 962 if (@_)
89 0 0 @_ % 2 == 0 ? :
2 0 @_ == 1 && ref $_[0] eq 'HASH' ? :
100 1 1 if @_
106 1 194 if @_
112 1 2 if @_
118 1 1 if @_
124 0 0 if @_
130 0 0 if @_
136 0 0 if @_
142 1 45 if @_
148 0 1 if $self->{'verbose'}
149 0 1 if @_
150 0 1 unless defined $self->{'word'}
151 0 1 unless keys %{$$self{"lexicon"};}
166 0 1 if $self->{'verbose'}
173 45 0 unless grep {$part =~ /$_/;} @{$self->constraints;}
177 0 1 if ($self->{'verbose'})
181 0 0 $last > length $part ? :
0 0 $last ? :
186 0 0 if @{$self->{'parts'};}
194 0 1 if $self->{'verbose'}
197 5 40 if $self->{'lexicon'}{$part}
200 0 1 if $self->{'verbose'}
206 0 1 if $self->{'verbose'}
219 0 1 if $self->{'verbose'}
240 192 64 unless (grep {$t =~ /$_/;} @{$$self{"constraints"};})
243 0 192 if $self->{'verbose'}
253 0 1 unless scalar keys %{$$self{"lexicon"};}
254 0 1 if $self->{'verbose'}
259 0 192 if exists $self->{'knowns'}{$combo}
270 108 852 if ($combo_seen)
282 0 192 if $self->{'verbose'}
283 85 107 if ($x or $y) { }
308 108 852 if (exists $lexicon->{$string}) { }
0 852 elsif (exists $$lexicon{"-$string"}) { }
0 852 elsif (exists $$lexicon{"$string-"}) { }
309 108 0 if defined $combo_seen
312 0 0 if defined $combo_seen
316 0 0 if defined $combo_seen
320 960 0 wantarray ? :
335 0 0 unless $self->{'knowns'}{$a}[0] <=> $self->{'knowns'}{$b}[0]
345 0 0 $self->{'definitions'}{$chunk} ? :
0 0 defined $self->{'definitions'}{$chunk} ? :
355 0 0 wantarray ? :
362 0 5 if $self->{'verbose'}
365 1 2 if ($file and $file eq "lexicon_file" and $value)
374 0 5 if $self->{'verbose'} and not $file
376 3 2 if ($file)
378 2 1 if (keys %{$$self{'lexicon'};}) { }
379 0 2 if $self->{'verbose'}
384 0 1 if $self->{'verbose'} and -e $file
385 1 0 if -e $file