Branch Coverage

blib/lib/Wiktionary/Parser/Section/Translations.pm
Criterion Covered Total %
branch 47 62 75.8


line true false branch
127 0 0 if ($params[0] and scalar @params == 1)
136 0 0 if (my $link_meta = $params[1] =~ /\[\[([^\]]+)\]\]/)
140 0 0 if (scalar @link_params > 1) { }
155 0 0 if ($params[1])
181 106 270 if ($token =~ /^[fmcn]$/) { }
0 270 elsif ($token =~ /^[sp]$/) { }
104 166 elsif ($token =~ /^tr=(.+)/) { }
75 91 elsif ($token =~ /^sc=(.+)/) { }
15 76 elsif ($token =~ /^alt=(.+)/) { }
76 0 elsif ($token =~ /^xs=(.+)/) { }
241 2 2 if ($gp =~ /[mfcn]/) { }
2 0 elsif ($gp =~ /[ps]/) { }
272 0 1206 unless defined $meta
274 24 1182 if ($$meta{'word_sense'})
276 0 24 if ($self->get_current_word_sense)
288 5 1177 if ($$meta{'meta'} and $$meta{'meta'} eq 'end_word_sense')
292 97 1085 if ($$meta{'meta'} and $$meta{'meta'} eq 'end_segment')
293 96 1 if ($self->get_current_word_sense)
300 0 412 unless $$meta{'translations'}
412 770 if $$meta{'translations'}
301 133 1049 if $$meta{'gender'}
302 2 1180 if $$meta{'number'}
303 108 1074 if $$meta{'transliteration'}
304 15 1167 if $$meta{'alternate'}
306 0 13 unless $$meta{'qualifier'}
13 1169 if $$meta{'qualifier'}
308 310 872 if $$meta{'language'}
309 327 855 if $$meta{'language_code'}
313 336 9 if ($self->get_current_word_sense and $lexeme)
328 1206 12729 if (my(@matches) = $_[0] =~ /^$pattern/)
357 20 20 unless $$self{'word_senses'}