Esempio n. 1
0
        public void PlayerCountSix_IsValid()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();

            //Assert
            Assert.AreEqual(playerList.Count, 6);
        }
Esempio n. 2
0
        public void CreatePlayerList_IsValid()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();

            //Assert
            Assert.IsInstanceOfType(playerList, typeof(List <Player>));
        }
Esempio n. 3
0
        public void HasPilot_IsValid()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();

            var item = playerList.SingleOrDefault(x => x.Name == "Pilot");

            //Assert
            Assert.AreEqual(item.Colour, PlayerColour.Blue.ToString());
            Assert.AreEqual(item.Action, PlayerConstants.PILOT_ACTION);
            Assert.AreEqual(item.Name, "Pilot");
        }
Esempio n. 4
0
        public void HasDiver_IsValid()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();

            var item = playerList.SingleOrDefault(x => x.Name == "Diver");

            //Assert
            Assert.AreEqual(item.Colour, PlayerColour.Black.ToString());
            Assert.AreEqual(item.Action, PlayerConstants.DIVER_ACTION);
            Assert.AreEqual(item.Name, "Diver");
        }
Esempio n. 5
0
        public void HasNavigator_IsValid()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();

            var item = playerList.SingleOrDefault(x => x.Name == "Navigator");

            //Assert
            Assert.AreEqual(item.Colour, PlayerColour.Yellow.ToString());
            Assert.AreEqual(item.Action, PlayerConstants.NAVIGATOR_ACTION);
            Assert.AreEqual(item.Name, "Navigator");
        }
Esempio n. 6
0
        public void AllPlayersDontHaveTreasureStatue()
        {
            //Arrange
            var playerListFactory = new PlayerListFactory();

            //Act
            var playerList = playerListFactory.Create();


            foreach (var player in playerList)
            {
                Assert.IsFalse(player.HasCrystalOfFireTreasureStatue);
                Assert.IsFalse(player.HasEarthStoneTreasureStatue);
                Assert.IsFalse(player.HasOceansChaliceTreasureStatue);
                Assert.IsFalse(player.HasStatueOfTheWindTreasureStatue);
            }
        }