public void TestIfResetMethodCorrectlyResetsTheUserMovesCount() { var gameModel = new GameModel(); gameModel.IncrementMoves(); gameModel.ResetUserMoves(); Assert.AreEqual(0, gameModel.UserMovesCount); }
public void TestIfGetterEncapsulatesTheCurrentState() { var game = new GameModel(); this.logic.RandomizeBalloonField(game.Field); this.memento.SaveState(game); var state = this.memento.GetState(); state.Field[0, 0].Number = 99; Assert.AreNotEqual(game.Field[0, 0].Number, 99); var moves = state.UserMovesCount; game.IncrementMoves(); var moves2 = game.UserMovesCount; Assert.AreNotEqual(moves, moves2); }
public void TestIfIncrementMovesMethodCorrectlyIncrementTheMovesCount() { var gameModel = new GameModel(); gameModel.IncrementMoves(); Assert.AreEqual(1, gameModel.UserMovesCount); }