Forgot the test name change

This commit is contained in:
egut125
2021-12-30 23:52:09 -05:00
parent 5dbb5c86d4
commit 430b6f5394
2 changed files with 3 additions and 3 deletions

View File

@@ -184,5 +184,5 @@ class GameStats:
if __name__ == "__main__":
game_stats = GameStats()
game_stats.log_item_pickup("rune_12", True)
game_stats.log_item_keep("rune_12", True)
game_stats._save_stats_to_file()

View File

@@ -16,10 +16,10 @@ class TestGameStats:
("some_potion", False),
("super_healing_potion", False),
])
def test_log_item_pickup(self, item_name: str, item_should_be_added: bool):
def test_log_item_keep(self, item_name: str, item_should_be_added: bool):
self.game_stats.update_location("test_location")
previous_item_count = len(self.game_stats._location_stats["test_location"]["items"])
self.game_stats.log_item_pickup(item_name, send_message=False)
self.game_stats.log_item_keep(item_name, send_message=False)
new_item_count = len(self.game_stats._location_stats["test_location"]["items"])
item_was_added = previous_item_count < new_item_count
assert(item_was_added == item_should_be_added)