public void GetSquare_WithInvalidPosition() { // Arrange WrapperBattleshipBoard wrp = new WrapperBattleshipBoard(); wrp.BuildShips(); Tuple <char, int> position = new Tuple <char, int>('M', 10); // Act and assert Assert.ThrowsException <InvalidOperationException>(() => wrp.GetSquareFromComputerOcean(position)); }
static void Main(string[] args) { wprBattleshipBoard = new WrapperBattleshipBoard(); wprBattleshipBoard.BuildShips(); Console.WriteLine("I built 3 ships, Are you ready?"); while (true) { if (UserPlay()) { break; } if (ComputerPlay()) { break; } } Console.ReadKey(); }