Write test to check rover has item in inventory
This commit is contained in:
parent
f0d40cc46c
commit
71c2c09270
2 changed files with 18 additions and 0 deletions
|
@ -164,4 +164,9 @@ func TestWorld_RoverStash(t *testing.T) {
|
|||
tile, err := world.Atlas.GetTile(pos)
|
||||
assert.NoError(t, err, "Failed to get tile")
|
||||
assert.Equal(t, objects.Empty, tile, "Stash failed to remove object from atlas")
|
||||
|
||||
inv, err := world.RoverInventory(a)
|
||||
assert.NoError(t, err, "Failed to get inventory")
|
||||
assert.Equal(t, Item{Type: objects.SmallRock}, inv[0])
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue