blib/lib/Game/Battleship.pm | |||
---|---|---|---|
Criterion | Covered | Total | % |
branch | 10 | 22 | 45.4 |
line | true | false | branch |
---|---|---|---|
22 | 3 | 0 | unless ($i) |
29 | 0 | 3 | if $n > $_ |
39 | 0 | 3 | if (exists $self->{'players'}{$who}) |
45 | 0 | 3 | unless $player |
48 | 0 | 3 | if (ref $player eq 'Game::Battleship::Player') { } |
0 | 3 | elsif (ref $player eq 'HASH') { } | |
80 | 7 | 18 | if ($_ eq $name or $self->{'players'}{$_}->name eq $name or $self->{'players'}{$_}->id eq $name) |
90 | 1 | 9 | unless $player |
102 | 0 | 0 | unless $player->life |
106 | 0 | 0 | if $opponent->name eq $player->name or not $opponent->life |
121 | 0 | 0 | @alive == 1 ? : |