diff --git a/squirrelbattle/tests/game_test.py b/squirrelbattle/tests/game_test.py index 9c14d40..4a57ba0 100644 --- a/squirrelbattle/tests/game_test.py +++ b/squirrelbattle/tests/game_test.py @@ -7,7 +7,7 @@ import unittest from ..bootstrap import Bootstrap from ..display.display import Display from ..display.display_manager import DisplayManager -from ..entities.friendly import Sunflower +from ..entities.friendly import Sunflower, Merchant from ..entities.items import Bomb from ..entities.player import Player from ..enums import DisplayActions @@ -35,7 +35,14 @@ class TestGame(unittest.TestCase): """ bomb = Bomb() self.game.map.add_entity(bomb) + # Add an item in the inventory to check that it is well loaded bomb.hold(self.game.player) + + # Ensure that merchants can be saved + merchant = Merchant() + merchant.move(3, 6) + self.game.map.add_entity(merchant) + old_state = self.game.save_state() self.game.handle_key_pressed(KeyValues.DOWN)