def loadPokemonFromXML(self, trainer, tree): """ Loads the Trainer's Pokemon from XML """ pokemon = [] tree = tree.find(Tags.beltTag) for pkmn in tree.getiterator(Tags.pokemonTag): pokemon.append(PokemonFactory.loadFromXML(pkmn)) trainer.beltPokemon = pokemon
def BuildPokemon(pkmn="BULBASAUR"): """ Builds a Pokemon """ return PokemonFactory.buildStarter(pkmn)
def setUp(self): """ Build the *** for the test """ self.pkmn = BuildPokemon() self.copy = PokemonFactory.copy(self.pkmn)
def BuildPokemon(pkmn = "BULBASAUR"): """ Builds a Pokemon """ return PokemonFactory.buildStarter(pkmn)
def setPkmn(self, pkmn): """ Set the PkmnBattleWrapper's Pokemon """ self.original = pkmn self.pkmn = PokemonFactory.copy(pkmn)