Skip to content

Commit

Permalink
[tests] Grid.move_to
Browse files Browse the repository at this point in the history
  • Loading branch information
jofmi committed Jun 14, 2021
1 parent c0e4c6c commit bd726f2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tests/test_grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ def test_move():
agent = agents[0]
assert grid.attr_grid('id').tolist()[0] == [1., 2.]
grid.move_to(agent, (1, 0)) # Move in absolute terms
grid.move_to(agent, (1, 0)) # Moving to same pos causes no error
assert grid.attr_grid('id').tolist()[0][1] == 2.0
assert grid.attr_grid('id').tolist()[1][0] == 1.0
assert np.isnan(grid.attr_grid('id').tolist()[1][1])
Expand Down

0 comments on commit bd726f2

Please sign in to comment.