| blib/lib/Game/DijkstraMap.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| condition | 69 | 101 | 68.3 |
| line | !l | l&&!r | l&&r | condition |
|---|---|---|---|---|
| 44 | 8 | 0 | 1 | exists $param->{'map'} and exists $param->{'str2map'} |
| 56 | 3 | 1 | 6 | $x >= 0 and $x <= $maxcol |
| 60 | 9 | 3 | 18 | $x >= 0 and $x <= $maxrow |
| 12 | 3 | 15 | $x >= 0 and $x <= $maxrow and $y >= 0 | |
| 6 | 1 | 14 | $x >= 0 and $x <= $maxrow and $y >= 0 and $y <= $maxcol | |
| 73 | 15 | 9 | 26 | $r > 0 and $c > 0 |
| 74 | 15 | 10 | 25 | $r > 0 and $c < $maxcol |
| 75 | 13 | 12 | 25 | $r < $maxrow and $c > 0 |
| 76 | 13 | 9 | 28 | $r < $maxrow and $c < $maxcol |
| 154 | 4 | 0 | 20 | $x >= 0 and $x <= $maxcol |
| 158 | 12 | 0 | 60 | $x >= 0 and $x <= $maxrow |
| 12 | 4 | 56 | $x >= 0 and $x <= $maxrow and $y >= 0 | |
| 4 | 0 | 56 | $x >= 0 and $x <= $maxrow and $y >= 0 and $y <= $maxcol | |
| 268 | 145 | 221 | 166 | $nv < $best and $nv >= $mincost |
| 311 | 98 | 4 | 84 | $nr->[0] < $best->[0] and $nr->[0] >= $mincost |
| line | l | !l | condition |
|---|---|---|---|
| 104 | 9 | 0 | $param->{'my_weight'} // 1 |
| 111 | 16 | 0 | $param->{'weights'}[$h] // 0 |
| 219 | 1 | 0 | $param->{'my_weight'} // 1 |
| 226 | 2 | 0 | $param->{'weights'}[$h] // 0 |
| 238 | 4 | 0 | $param->{'weights'}[$k] // 0 |
| 240 | 2 | 0 | $param->{'my_weight'} // 1 |
| 254 | 1 | 6 | $avfn //= \&Game::DijkstraMap::adjacent_values_sq |
| line | l | !l&&r | !l&&!r | condition |
|---|---|---|---|---|
| 122 | 0 | 1 | 7 | not defined $map or ref $map ne 'ARRAY' |
| 1 | 0 | 7 | not defined $map or ref $map ne 'ARRAY' or not defined $map->[0] | |
| 1 | 0 | 7 | not defined $map or ref $map ne 'ARRAY' or not defined $map->[0] or ref $map->[0] ne 'ARRAY' | |
| 146 | 0 | 0 | 13 | $r > $maxrow or $r < 0 |
| 147 | 0 | 0 | 13 | $c > $maxcol or $c < 0 |
| 149 | 1 | 11 | 1 | $value //= $dimap->[$r][$c] |
| 187 | 0 | 0 | 6 | $r > $maxrow or $r < 0 |
| 188 | 0 | 0 | 6 | $c > $maxcol or $c < 0 |
| 190 | 0 | 5 | 1 | $value //= $dimap->[$r][$c] |
| 357 | 0 | 6 | 0 | $lf //= $/ |
| 407 | 0 | 0 | 1 | $r > $maxrow or $r < 0 |
| 408 | 0 | 0 | 1 | $c > $maxcol or $c < 0 |
| 425 | 0 | 0 | 29 | $r > $maxrow or $r < 0 |
| 426 | 0 | 0 | 29 | $c > $maxcol or $c < 0 |