Reaching 100% coverage and renamed an unused loop variable
This commit is contained in:
parent
1e5bb26f57
commit
984b12421b
@ -161,7 +161,7 @@ class TestEntities(unittest.TestCase):
|
||||
self.assertFalse(player.move_up())
|
||||
self.assertTrue(player.move_left())
|
||||
self.assertFalse(player.move_left())
|
||||
for i in range(8):
|
||||
for _ in range(8):
|
||||
self.assertTrue(player.move_down())
|
||||
self.assertFalse(player.move_down())
|
||||
self.assertTrue(player.move_right())
|
||||
|
@ -17,6 +17,7 @@ class TestGame(unittest.TestCase):
|
||||
"""
|
||||
self.game = Game()
|
||||
self.game.new_game()
|
||||
self.game.logs.add_message("Hello World !")
|
||||
display = DisplayManager(None, self.game)
|
||||
self.game.display_actions = display.handle_display_action
|
||||
|
||||
@ -260,7 +261,6 @@ class TestGame(unittest.TestCase):
|
||||
"""
|
||||
Tests the use of logs
|
||||
"""
|
||||
self.game.logs.add_message("Hello World !")
|
||||
self.assertEqual(self.game.logs.messages, ["Hello World !"])
|
||||
self.game.logs.add_messages(["Hello", "World"])
|
||||
self.assertEqual(self.game.logs.messages, ["Hello World !",
|
||||
|
Loading…
Reference in New Issue
Block a user