public void Setup() { //A G game = new TicTacToeClass(); //A W game.newGame(); }
public void savingTheBoard() { var gateway = Substitute.For <IDBgateway>(); TicTacToeClass newgame = new TicTacToeClass(gateway); newgame.newGame(); //newgame.nextMove('X', 0); newgame.SaveTheBoard(); char[] expectedBoard = new char[9] { 'E', 'E', 'E', 'E', 'E', 'E', 'E', 'E', 'E' }; gateway.Received().save(expectedBoard); //Assert.AreEqual(expectedBoard, newgame.getTheBoard()); }