Condition Coverage

blib/lib/Lingua/ID/Nums2Words.pm
Criterion Covered Total %
condition 51 62 82.2


and 2 conditions

line l !l condition
116 0 25 $num =~ /^(.+)(?:\Q$Lingua::ID::Nums2Words::Dec_char\E)?$/o and @words = _handle_int $1
163 47 4 $n3 > 1 and @words = ($Lingua::ID::Nums2Words::Digit_words{$n3}, 'ratus')

and 3 conditions

line !l l&&!r l&&r condition
101 25 0 4 $num =~ /^(.+)[Ee](.+)$/ and @words = (_handle_neg_dec $1, $Lingua::ID::Nums2Words::Exp_word, _handle_neg_dec $2)
116 25 0 8 $num =~ /^(.+)\Q$Lingua::ID::Nums2Words::Dec_char\E(.+)$/o and @words = (_handle_int $1, $Lingua::ID::Nums2Words::Dec_word, _handle_dec $2)
25 0 0 $num =~ /^\Q$Lingua::ID::Nums2Words::Dec_char\E(.+)$/o and @words = ($Lingua::ID::Nums2Words::Digit_words{'0'}, $Lingua::ID::Nums2Words::Dec_word, _handle_dec $1)
159 17 2 1 $n1 == 1 and $order == 1
19 0 1 $n1 == 1 and $order == 1 and @words = 'se'
10 9 38 $n3 == 0 and $n2 == 0
19 18 20 $n3 == 0 and $n2 == 0 and $n1 > 0
163 51 0 6 $n3 == 1 and @words = 'seratus'
166 3 0 6 $n1 == 0 and push @words, 'sepuluh'
1 0 2 $n1 == 1 and push @words, 'sebelas'
177 47 7 3 $n3 > 0 and $n2 == 0
54 1 2 $n3 > 0 and $n2 == 0 and $n1 > 0

or 2 conditions

line l !l condition
159 1 2 $n1 == 1 and $order == 1 and @words = 'se' or @words = $Lingua::ID::Nums2Words::Digit_words{$n1}
166 2 1 $n1 == 0 and push @words, 'sepuluh' or $n1 == 1 and push @words, 'sebelas' or push @words, $Lingua::ID::Nums2Words::Digit_words{$n1}, 'belas'

or 3 conditions

line l !l&&r !l&&!r condition
116 8 0 25 $num =~ /^(.+)\Q$Lingua::ID::Nums2Words::Dec_char\E(.+)$/o and @words = (_handle_int $1, $Lingua::ID::Nums2Words::Dec_word, _handle_dec $2) or $num =~ /^\Q$Lingua::ID::Nums2Words::Dec_char\E(.+)$/o and @words = ($Lingua::ID::Nums2Words::Digit_words{'0'}, $Lingua::ID::Nums2Words::Dec_word, _handle_dec $1)
166 6 0 3 $n1 == 0 and push @words, 'sepuluh' or $n1 == 1 and push @words, 'sebelas'
180 10 9 38 $n3 != 0 or $n2 != 0
19 20 18 $n3 != 0 or $n2 != 0 or $n1 != 0
208 43 1 130 not length $w or $w eq 'se'
44 10 120 not length $w or $w eq 'se' or not @_