예제 #1
0
class removePreviousLeech(unittest.TestCase):
    """ Test that removePreviousLeech actually removes a leech effect """
    
    def setUp(self):
        """ Builds the delegate and pkmn for use in the tests """
        self.wrapper = BuildPokemonBattleWrapper()
        self.delegate = LeechDelegate("", "", "FIRE")
        self.leech = Leech(None, "")
        
    def removeLeech(self):
        """ Tests if the leech is removed """
        self.wrapper.secondaryEffects = [self.leech]
        self.delegate.removePreviousLeech(self.wrapper)
        
        assert not self.leech in self.wrapper.secondaryEffects, "Should have removed original trap effect"