Ejemplo n.º 1
0
        public void CheckGetPokemonByName()
        {
            P1.Pokedex kanto  = new P1.Pokedex(@"D:\Users\arobi\Desktop\pokemondatabase.txt");
            P1.Pokemon rhydon = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);

            Assert.IsTrue(kanto.getPokemonByName("Rhydon") == rhydon);
        }
Ejemplo n.º 2
0
        public void CheckPokemonToString()
        {
            P1.Pokemon rhydon     = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);
            string     testString = "Pokemon: Rhydon\nTypes: Ground-Rock\n";

            Assert.IsTrue(testString.Equals(rhydon.ToString()));
        }
Ejemplo n.º 3
0
 public void CheckWeaknessesAndResistances()
 {
     P1.Pokemon rhydon = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);
     Assert.AreEqual(4.0, P1.Pokedex.getWeaknessVal(rhydon, P1.Pokemon.Type.Grass), "Incorrect Value: Rhydon is 4x times weak to grass");
 }
Ejemplo n.º 4
0
 public void CheckIsEqual()
 {
     P1.Pokemon pokemon1 = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);
     P1.Pokemon pokemon2 = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);
     Assert.IsTrue(pokemon1 == pokemon2);
 }
Ejemplo n.º 5
0
 public void CheckPokemonCreation()
 {
     P1.Pokemon pokemon = new P1.Pokemon("Rhydon", P1.Pokemon.Type.Ground, P1.Pokemon.Type.Rock);
     Assert.IsTrue(pokemon.Name.Equals("Rhydon") && pokemon.PrimaryType.Equals(P1.Pokemon.Type.Ground) && pokemon.SecondaryType.Equals(P1.Pokemon.Type.Rock), "Test Pokemon Creation Successful");
 }