예제 #1
0
        public void AnyBoats_ABoat_True()
        {
            var battleShipGrid = new BoardState(new List <BattleShip> {
                new BattleShip {
                    Fields = new List <string> {
                        "A1"
                    }
                }
            });

            Assert.That(battleShipGrid.AnyBoats(), Is.True);
        }
예제 #2
0
        public void AnyBoats_NoBoats_False()
        {
            var battleShipGrid = new BoardState(new List <BattleShip> {
                new BattleShip {
                    Fields = new List <string> {
                        "A1"
                    }
                }
            });

            battleShipGrid.HitLocations.Add("A1");

            Assert.That(battleShipGrid.AnyBoats(), Is.False);
        }