public void TestThatTwoAiPlayersCanPlayAgainstEachOther() { randomMovesAiPlayer.Turn = PieceColor.White; chessboard = new ChessboardClassic(); var secondAiPlayer = new RandomMovesAIPlayer { Turn = PieceColor.Black }; var firstAiPlayerMoveResponses = new List <AIResponse>(); var secondAiPlayerMoveResponses = new List <AIResponse>(); for (var i = 0; i < 3; i++) { var firstPlayerResponse = randomMovesAiPlayer.PerformMove(chessboard); var secondPlayerResponse = secondAiPlayer.PerformMove(chessboard); firstAiPlayerMoveResponses.Add(firstPlayerResponse); secondAiPlayerMoveResponses.Add(secondPlayerResponse); } Assert.IsTrue(firstAiPlayerMoveResponses.All(x => x == AIResponse.SuccessfulMove)); Assert.IsTrue(secondAiPlayerMoveResponses.All(x => x == AIResponse.SuccessfulMove)); // TODO: Also test that not all pieces are in their original positions }
public void Setup() { chessboard = new ChessboardClassic(); randomMovesAiPlayer = new RandomMovesAIPlayer(); }