예제 #1
0
        public void NPTrainerInstanceHasCorrectMethods()
        {
            // arrange
            var brook    = new NPTrainer("Brook", 4);
            var watermon = new WaterPokemon();

            // act
            brook.catchPokemon(watermon);

            // assert
            Assert.Equal(4, brook.Animosity);
            Assert.Same(watermon, brook.Pocket[0]);
        }
예제 #2
0
        public void BattleFightsTwoTrainersWithPokemon()
        {
            // arrange
            var brook    = new NPTrainer("Brook", 4);
            var misty    = new Player("Misty", "bubbly");
            var firemon  = new FirePokemon();
            var watermon = new WaterPokemon();

            // act
            brook.catchPokemon(watermon);
            misty.catchPokemon(firemon);

            var battle = new Battle(misty, brook);

            battle.Fight();

            // assert
        }