Test player level up

This commit is contained in:
Yohann D'ANELLO
2020-11-06 21:23:17 +01:00
parent 0de11abfa8
commit aeb43a0cec
3 changed files with 13 additions and 7 deletions

View File

@@ -95,3 +95,8 @@ class TestEntities(unittest.TestCase):
self.assertFalse(player.move_right())
self.assertTrue(player.move_down())
self.assertTrue(player.move_down())
player.add_xp(70)
self.assertEqual(player.current_xp, 10)
self.assertEqual(player.max_xp, 40)
self.assertEqual(player.level, 4)