use of pokeraidbot.domain.pokemon.Pokemon in project pokeraidbot by magnusmickelsson.
the class PokemonRepositoryTest method testGetTyranitarWithFuzzySearch.
@Test
public void testGetTyranitarWithFuzzySearch() throws Exception {
Pokemon pokemon = pokemonRepository.search("Tyranitar", null);
assertThat(pokemon != null, is(true));
assertThat(pokemon.getTypes(), is(new PokemonTypes("Dark", "Rock")));
Pokemon search = pokemonRepository.search("Tryantar", null);
assertThat(search, is(pokemon));
}
use of pokeraidbot.domain.pokemon.Pokemon in project pokeraidbot by magnusmickelsson.
the class UtilsTest method testPrintWeaknesses.
@Test
public void testPrintWeaknesses() throws Exception {
PokemonRepository pokemonRepository = new PokemonRepository("/pokemons.csv", new LocaleService("sv", userConfigRepository));
Pokemon pokemon = pokemonRepository.search("Tyranitar", null);
assertThat(Utils.printWeaknesses(pokemon), is("Water, **Fighting**, Ground, Grass, Steel, Bug, Fairy"));
}
use of pokeraidbot.domain.pokemon.Pokemon in project pokeraidbot by magnusmickelsson.
the class UtilsTest method testDoubleWeaknesses.
@Test
public void testDoubleWeaknesses() throws Exception {
Pokemon pokemon;
String typeToCheck;
pokemon = pokemonRepository.search("Tyranitar", null);
typeToCheck = "Fighting";
assertPokemonIsDoubleWeakAgainst(pokemon, typeToCheck);
pokemon = pokemonRepository.search("Articuno", null);
typeToCheck = "Rock";
assertPokemonIsDoubleWeakAgainst(pokemon, typeToCheck);
}
use of pokeraidbot.domain.pokemon.Pokemon in project pokeraidbot by magnusmickelsson.
the class PokemonRepositoryTest method testGetRaikouWithFuzzySearchFirstChars.
@Test
public void testGetRaikouWithFuzzySearchFirstChars() throws Exception {
Pokemon pokemon = pokemonRepository.search("Raikou", null);
assertThat(pokemon != null, is(true));
assertThat(pokemon.getTypes(), is(new PokemonTypes("Electric")));
Pokemon search = pokemonRepository.search("Raik", null);
assertThat(search, is(pokemon));
assertThat(pokemon.isEgg(), is(false));
}
use of pokeraidbot.domain.pokemon.Pokemon in project pokeraidbot by magnusmickelsson.
the class PokemonRepositoryTest method assertEggExistsForTier.
private void assertEggExistsForTier(String eggName, String eggSearchName, int eggTier) {
Pokemon pokemon = pokemonRepository.search(eggName + eggTier, null);
assertThat(pokemon != null, is(true));
assertThat(pokemon.getTypes(), is(new PokemonTypes()));
Pokemon search = pokemonRepository.search(eggSearchName + eggTier, null);
assertThat(search, is(pokemon));
assertThat(pokemon.isEgg(), is(true));
}
Aggregations