DEV-765 add some additional tests (#65)
Adds additional test coverage. Re-uses standard test cases where possible and added a few additional cases specific to some modes.
This commit is contained in:
parent
9cf20bb8ab
commit
5e629e9e93
8 changed files with 655 additions and 196 deletions
|
|
@ -60,6 +60,9 @@ func (r *WrappedRuleset) moveSnakes(b *BoardState, moves []SnakeMove) error {
|
|||
|
||||
for i := 0; i < len(b.Snakes); i++ {
|
||||
snake := &b.Snakes[i]
|
||||
if snake.EliminatedCause != NotEliminated {
|
||||
continue
|
||||
}
|
||||
snake.Body[0].X = replace(snake.Body[0].X, 0, b.Width-1)
|
||||
snake.Body[0].Y = replace(snake.Body[0].Y, 0, b.Height-1)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue