예제 #1
0
        public void Pokedex_GetPokemonByName_HappyPass()
        {
            Pokemon expect  = dex.Pokemons[0];
            Pokemon actural = dex.GetPokemonByName("Bulbasaur");

            Assert.AreEqual(actural, expect);
        }
예제 #2
0
 public void AddPokemon(Pokedex dex, string name)
 {
     try
     {
         Pokemon thePokemon = dex.GetPokemonByName(name);
         Pokemons.Add(thePokemon.Index);
     }
     catch (Exception e)
     {
         Console.WriteLine(e.Message);
     }
 }