Condition Coverage

blib/lib/Game/TextMapper/Traveller.pm
Criterion Covered Total %
condition 111 120 92.5


and 3 conditions

line !l l&&!r l&&r condition
120 3 30 48 $population >= 1 and $population <= 5
142 19 59 3 $atmosphere >= 2 and $hydro == 0
145 22 59 0 $hydro >= 1 and $atmosphere <= 1
148 22 51 8 $hydro >= 1 and $atmosphere >= 10
152 78 1 2 $population eq 0 and $law eq 0
79 0 2 $population eq 0 and $law eq 0 and $government eq 0
156 3 64 14 $population >= 1 and $population <= 3
160 31 8 42 $atmosphere >= 4 and $atmosphere <= 9
39 12 30 $atmosphere >= 4 and $atmosphere <= 9 and $hydro >= 4
20 9 21 $atmosphere >= 4 and $atmosphere <= 9 and $hydro >= 4 and $hydro <= 8
21 11 10 $atmosphere >= 4 and $atmosphere <= 9 and $hydro >= 4 and $hydro <= 8 and $population >= 5
20 2 8 $atmosphere >= 4 and $atmosphere <= 9 and $hydro >= 4 and $hydro <= 8 and $population >= 5 and $population <= 7
164 50 3 28 $atmosphere <= 3 and $hydro <= 3
53 18 10 $atmosphere <= 3 and $hydro <= 3 and $population >= 6
169 33 46 2 &any(sub { $atmosphere == $_; } , 0, 1, 2, 4, 7, 9) and $population >= 9
173 22 5 54 $government >= 4 and $government <= 9
27 44 10 $government >= 4 and $government <= 9 and $atmosphere == 6 || $atmosphere == 8
44 7 3 $government >= 4 and $government <= 9 and $atmosphere == 6 || $atmosphere == 8 and $population >= 6
51 0 3 $government >= 4 and $government <= 9 and $atmosphere == 6 || $atmosphere == 8 and $population >= 6 and $population <= 8
177 19 37 25 $atmosphere >= 2 and $atmosphere <= 5
56 10 15 $atmosphere >= 2 and $atmosphere <= 5 and $hydro <= 3
188 6 61 14 not $pirate_base and $atmosphere >= 10 || $population && $government == 0 || $population && $law == 0 || $government == 7 || $government == 10 || $law >= 9
279 1277 229 58 $d <= 2 and match(qr/^(starport-[AB]|naval)$/u, qr/^(starport-[AB]|naval)$/u, $system1, $system2)
282 1277 287 0 $d <= 2 and match(qr/^agriculture$/u, qr/^(agriculture|astroid|desert|high|industrial|low|non-agriculture|rich)$/u, $system1, $system2) || match(qr/^asteroid$/u, qr/^(asteroid|industrial|non-agriculture|rich|vacuum)$/u, $system1, $system2) || match(qr/^desert$/u, qr/^(desert|non-agriculture)$/u, $system1, $system2) || match(qr/^fluid$/u, qr/^(fluid|industrial)$/u, $system1, $system2) || match(qr/^high$/u, qr/^(high|low|rich)$/u, $system1, $system2) || match(qr/^ice$/u, qr/^industrial$/u, $system1, $system2) || match(qr/^industrial$/u, qr/^(agriculture|astroid|desert|fluid|high|industrial|non-industrial|poor|rich|vacuum|water)$/u, $system1, $system2) || match(qr/^low$/u, qr/^(industrial|rich)$/u, $system1, $system2) || match(qr/^non-agriculture$/u, qr/^(asteroid|desert|vacuum)$/u, $system1, $system2) || match(qr/^non-industrial$/u, qr/^industrial$/u, $system1, $system2) || match(qr/^rich$/u, qr/^(agriculture|desert|high|industrial|non-agriculture|rich)$/u, $system1, $system2) || match(qr/^vacuum$/u, qr/^(asteroid|industrial|vacuum)$/u, $system1, $system2) || match(qr/^water$/u, qr/^(industrial|rich|water)$/u, $system1, $system2)
326 1066 480 18 $d <= 3 and match(qr/^rich$/u, qr/^(asteroid|agriculture|desert|high|industrial|non-agriculture|water|rich|low)$/u, $system1, $system2)
343 3486 415 103 &any(sub { /$re1/u; } , @$sys1) and &any(sub { /$re2/u; } , @$sys2)
344 2955 917 29 &any(sub { /$re2/u; } , @$sys1) and &any(sub { /$re1/u; } , @$sys2)
364 46 31 55 $C{$u} && $C{$v}
368 46 31 16 $C{$u} and $C{$v}
59 0 18 $C{$v} and not $C{$u}
28 0 31 $C{$u} and not $C{$v}

or 3 conditions

line l !l&&r !l&&!r condition
74 19 8 54 $atmosphere < 2 or $atmosphere >= 10
75 18 3 60 $hydro < 0 or $size < 2
117 31 8 42 $atmosphere <= 3 or $atmosphere >= 10
123 7 8 66 $government == 0 or $government == 5
173 7 3 44 $atmosphere == 6 || $atmosphere == 8
188 10 10 39 $atmosphere >= 10 || $population && $government == 0 || $population && $law == 0 || $government == 7 || $government == 10 || $law >= 9
282 3 0 231 match(qr/^agriculture$/u, qr/^(agriculture|astroid|desert|high|industrial|low|non-agriculture|rich)$/u, $system1, $system2) || match(qr/^asteroid$/u, qr/^(asteroid|industrial|non-agriculture|rich|vacuum)$/u, $system1, $system2) || match(qr/^desert$/u, qr/^(desert|non-agriculture)$/u, $system1, $system2) || match(qr/^fluid$/u, qr/^(fluid|industrial)$/u, $system1, $system2) || match(qr/^high$/u, qr/^(high|low|rich)$/u, $system1, $system2) || match(qr/^ice$/u, qr/^industrial$/u, $system1, $system2) || match(qr/^industrial$/u, qr/^(agriculture|astroid|desert|fluid|high|industrial|non-industrial|poor|rich|vacuum|water)$/u, $system1, $system2) || match(qr/^low$/u, qr/^(industrial|rich)$/u, $system1, $system2) || match(qr/^non-agriculture$/u, qr/^(asteroid|desert|vacuum)$/u, $system1, $system2) || match(qr/^non-industrial$/u, qr/^industrial$/u, $system1, $system2) || match(qr/^rich$/u, qr/^(agriculture|desert|high|industrial|non-agriculture|rich)$/u, $system1, $system2) || match(qr/^vacuum$/u, qr/^(asteroid|industrial|vacuum)$/u, $system1, $system2) || match(qr/^water$/u, qr/^(industrial|rich|water)$/u, $system1, $system2)
364 77 16 39 not $C{$u} && $C{$v} or $C{$u} != $C{$v}
368 0 0 28 $C{$u} || $C{$v}