Пример #1
0
 def test_updates_map_with_correct_num_avatars(self):
     map = InfiniteMap()
     manager = DummyAvatarManager()
     manager.add_avatar(1, '', None)
     state = GameState(map, manager)
     state.update_environment()
     self.assertEqual(map.num_avatars, 1)
     manager.add_avatar(2, '', None)
     manager.add_avatar(3, '', None)
     state.update_environment()
     self.assertEqual(map.num_avatars, 3)
Пример #2
0
 def test_updates_map_with_correct_num_avatars(self):
     map = InfiniteMap()
     manager = DummyAvatarManager()
     manager.add_avatar(1, '', None)
     state = GameState(map, manager)
     state.update_environment()
     self.assertEqual(map.num_avatars, 1)
     manager.add_avatar(2, '', None)
     manager.add_avatar(3, '', None)
     state.update_environment()
     self.assertEqual(map.num_avatars, 3)
Пример #3
0
 def test_updates_map(self):
     map = InfiniteMap()
     state = GameState(map, DummyAvatarManager())
     state.update_environment()
     self.assertEqual(map.updates, 1)
Пример #4
0
 def test_updates_map(self):
     map = InfiniteMap()
     state = GameState(map, DummyAvatarManager())
     state.update_environment()
     self.assertEqual(map.updates, 1)