Exemple #1
0
 def test_unequip_item_not_equipped(self):
     self.logger.debug("test_unequip_item")
     item4 = game_system.Equipment()
     self.char.add_to_inventory(item4)
     self.assertIn(item4, self.char.inventory)
     self.char.unequip_item(item4)
     self.assertNotIn(item4, self.char.equipped)
Exemple #2
0
 def test_equip_item_not_in_inventory(self):
     self.logger.debug("test_equip_item_not_in_inventory")
     item4 = game_system.Equipment()
     with self.assertRaises(game_system.ItemNotInInventoryException):
         self.char.equip_item(item4)