Branch Coverage

blib/lib/Games/2048/Game.pm
Criterion Covered Total %
branch 17 26 65.3


line true false branch
22 10 20 unless @available_cells
24 20 0 rand() < 0.9 ? :
61 19 19 $reverse ? :
71 60 340 if ($self->cells_can_merge($cell, $next)) { }
102 238 elsif (not $self->tile($farthest)) { }
83 30 8 if ($moved)
96 0 0 if ($move_score)
100 0 0 if $self->score > $self->best_score
102 0 0 if ($move_score >= $self->goal and not $self->won and grep {$_->value >= $self->goal;} $self->each_tile)
108 0 0 unless ($self->has_moves_remaining)
121 288 185 if $tile and $next_tile and not $next_tile->merged
126 3 3 if $self->has_available_cells
130 1 72 if $self->cells_can_merge($cell, $next)