Repaired a merge error, tests now work.
This commit is contained in:
		@@ -275,7 +275,7 @@ class ChestInventoryDisplay(MenuDisplay):
 | 
			
		||||
    def trueheight(self) -> int:
 | 
			
		||||
        return 2 + super().trueheight
 | 
			
		||||
 | 
			
		||||
    def handle_click(self, y: int, x: int, game: Game) -> None:
 | 
			
		||||
    def handle_click(self, y: int, x: int, attr: int, game: Game) -> None:
 | 
			
		||||
        """
 | 
			
		||||
        We can select a menu item with the mouse.
 | 
			
		||||
        """
 | 
			
		||||
 
 | 
			
		||||
@@ -897,10 +897,11 @@ class TestGame(unittest.TestCase):
 | 
			
		||||
 | 
			
		||||
        # The second item is not a heart
 | 
			
		||||
        chest.inventory[1] = sword = Sword()
 | 
			
		||||
        # Take the second item by clicking on it
 | 
			
		||||
        # Take the second item
 | 
			
		||||
        item = self.game.chest_menu.validate()
 | 
			
		||||
        self.assertIn(item, chest.inventory)
 | 
			
		||||
        self.game.display_actions(DisplayActions.MOUSE, 7, 25)
 | 
			
		||||
        self.game.display_actions(DisplayActions.MOUSE, 7, 25,
 | 
			
		||||
                                  curses.BUTTON1_CLICKED)
 | 
			
		||||
        self.assertIn(item, self.game.player.inventory)
 | 
			
		||||
        self.assertNotIn(item, chest.inventory)
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user