public void FieldWithCity_BuyHotel_PlayerHaveNotEnoughtMoney_BuyHotelReturnFalse() { var field = new FieldWithCity("Brazylia", 1000, 1000); var player = new Player(1, "", "kamil", 1000, new Pawn("Red", 1, 0)); field.BuyField(player); field.BuyHome(player); field.BuyHome(player); field.BuyHome(player); field.BuyHotel(player); Assert.False(field.BuyHotel(player)); }
public void FieldWithCity_BuyHotel_PlayerHaveNotEnoughtMoney_FieldIsNotHotel() { var field = new FieldWithCity("Brazylia", 1000, 1000); var player = new Player(1, "", "kamil", 1000, new Pawn("Red", 1, 0)); field.BuyField(player); field.BuyHome(player); field.BuyHome(player); field.BuyHome(player); field.BuyHotel(player); Assert.AreNotEqual(field.GetFieldState, FieldState.Hotel); }
public void FieldWithCity_BuyHotel_PlayerHaveNotEnoughtMoney_FieldCostNotIncrease() { var field = new FieldWithCity("Brazylia", 1000, 1000); var player = new Player(1, "", "kamil", 1000, new Pawn("Red", 1, 0)); field.BuyField(player); field.BuyHome(player); field.BuyHome(player); field.BuyHome(player); field.BuyHotel(player); Assert.AreEqual(field.FieldCost, 1000); }
public void FieldWithCity_BuyHotel_PlayerHaveEnoughtMoney_PlayerSpendMoney() { var field = new FieldWithCity("Brazylia", 1000, 1000); var player = new Player(1, "", "kamil", 11000, new Pawn("Red", 1, 0)); field.BuyField(player); field.BuyHome(player); field.BuyHome(player); field.BuyHome(player); field.BuyHotel(player); Assert.AreEqual(player.Money, 0); }