Condition Coverage

blib/lib/Lingua/IND/Nums2Words.pm
Criterion Covered Total %
condition 50 75 66.6


and 2 conditions

line l !l condition
99 0 13 $num =~ /^(.+)(?:\Q$Dec_char\E)?$/o and @words = n2w3($1)
154 16 6 $n3 > 1 and @words = ($Digit_words{$n3}, 'ratus')

and 3 conditions

line !l l&&!r l&&r condition
79 13 0 0 $num =~ /^(.+)[Ee](.+)$/ and @words = (n2w2($1), $Exp_word, n2w2($2))
99 13 0 0 $num =~ /^(.+)\Q$Dec_char\E(.+)$/o and @words = (n2w3($1), $Dec_word, n2w5($2))
13 0 0 $num =~ /^\Q$Dec_char\E(.+)$/o and @words = ($Digit_words{'0'}, $Dec_word, n2w5($1))
150 2 3 1 $n1 == 1 and $order == 1
5 0 1 $n1 == 1 and $order == 1 and @words = 'se'
9 2 14 $n3 == 0 and $n2 == 0
11 8 6 $n3 == 0 and $n2 == 0 and $n1 > 0
154 22 0 3 $n3 == 1 and @words = 'seratus'
157 0 0 1 $n1 == 0 and push @words, 'sepuluh'
0 0 0 $n1 == 1 and push @words, 'sebelas'
168 16 6 3 $n3 > 0 and $n2 == 0
22 3 0 $n3 > 0 and $n2 == 0 and $n1 > 0

or 2 conditions

line l !l condition
73 14 1 shift() // (return '')
90 13 0 shift() // (return '')
119 13 0 shift() // (return '')
127 24 1 $t || 0
142 25 0 shift() // (return '')
150 1 3 $n1 == 1 and $order == 1 and @words = 'se' or @words = $Digit_words{$n1}
178 5 1 shift() // (return '')

or 3 conditions

line l !l&&r !l&&!r condition
99 0 0 13 $num =~ /^(.+)\Q$Dec_char\E(.+)$/o and @words = (n2w3($1), $Dec_word, n2w5($2)) or $num =~ /^\Q$Dec_char\E(.+)$/o and @words = ($Digit_words{'0'}, $Dec_word, n2w5($1))
157 1 0 0 $n1 == 0 and push @words, 'sepuluh' or $n1 == 1 and push @words, 'sebelas'
0 0 0 $n1 == 0 and push @words, 'sepuluh' or $n1 == 1 and push @words, 'sebelas' or push @words, $Digit_words{$n1}, 'belas'
171 9 2 14 $n3 != 0 or $n2 != 0
11 6 8 $n3 != 0 or $n2 != 0 or $n1 != 0
205 19 1 75 not length $w or $w eq 'se'
20 7 68 not length $w or $w eq 'se' or not @a