Пример #1
0
        public void Birthday_WithTwoOtherPlayers_ShouldCollect20Dollars()
        {
            Monopoly game     = new Monopoly(null, null, null);
            Board    board    = new CardBoard();
            Birthday birthday = new Birthday();
            Player   horse    = new Player("Horse");
            Player   car      = new Player("Car");
            Player   shoe     = new Player("Shoe");

            game.AddPlayer(horse);
            game.AddPlayer(car);
            game.AddPlayer(shoe);
            board.AddPlayerToBoard(car, 0);
            board.AddPlayerToBoard(horse, 0);
            board.AddPlayerToBoard(shoe, 0);

            birthday.Execute(horse);

            Assert.Equal(20, horse.Bank);
            Assert.Equal(-10, car.Bank);
            Assert.Equal(-10, shoe.Bank);
        }