[TestMethod] // 12 public void PerfectGame() { var game = new Game(); SimulateRoll(game, 12, 10); Assert.AreEqual(300, game.Score()); }
[TestMethod] // 7 public void StrikeFirstFrameGuttersRest() { var game = new Game(); game.Roll(10); SimulateRoll(game, 19, 0); Assert.AreEqual(10, game.Score()); }
[TestMethod] // 2 public void ScoreWithOutStrikesOrSpares() { var game = new Game(); SimulateRoll(game, 20, 1); Assert.AreEqual(20, game.Score()); }
[TestMethod] // 1 public void AllGutterBallsEqualZero() { var game = new Game(); SimulateRoll(game, 20, 0); Assert.AreEqual(0, game.Score()); }
[TestMethod] // 6 public void LastFrameSpareBonusBall() { var game = new Game(); SimulateRoll(game, 18, 3); game.Roll(10); game.Roll(10); game.Roll(10); Assert.AreEqual(84, game.Score()); }
[TestMethod] // 3 public void SpareInFirstFollowedByGutterBallsInRest() { var game = new Game(); game.Roll(4); game.Roll(6); SimulateRoll(game, 18, 0); Assert.AreEqual(10, game.Score()); }
[TestMethod] // 4 public void SpareInFirstPlusBallBonusGuttersForRest() { var game = new Game(); game.Roll(5); game.Roll(5); game.Roll(1); SimulateRoll(game, 17, 0); Assert.AreEqual(12, game.Score()); }
[TestMethod] // 13 public void AllSpares() { var game = new Game(); for (int i = 0; i < 21; i++) { game.Roll(5); } Assert.AreEqual(150, game.Score()); }
[TestMethod] // 11 public void GuttersThreeStrikesLastFrame() { var game = new Game(); SimulateRoll(game, 18, 0); game.Roll(10); game.Roll(10); game.Roll(10); Assert.AreEqual(30, game.Score()); }
[TestMethod] // 10 public void StrikeInLastFrameBonusBall() { var game = new Game(); SimulateRoll(game, 18, 4); game.Roll(10); game.Roll(10); game.Roll(10); Assert.AreEqual(102, game.Score()); }
[TestMethod] // 8 public void StrikeFirstFramePlusTwoBallBonusGuttersRest() { var game = new Game(); game.Roll(10); game.Roll(5); game.Roll(0); game.Roll(5); game.Roll(0); SimulateRoll(game, 15, 0); Assert.AreEqual(25, game.Score()); }
[TestMethod] // 5 public void ConsecutiveSparesMultipleBonuses() { var game = new Game(); game.Roll(5); game.Roll(5); game.Roll(5); game.Roll(5); SimulateRoll(game, 16, 4); Assert.AreEqual(93, game.Score()); }
public void When_AllRoll_Equals_0_Score_Should_Return_0() { RollMany(20, 0); Assert.Equal(0, _game.Score()); }
public void TestGutterGame() { rollMany(20, 0); Assert.Equal(0, g.Score()); }
public void TestGutterGame() { SetUp(); RollMany(20, 0); Assert.AreEqual(0, game.Score()); }
public void NewGameInitialised() { Assert.Equal(0, _game.Score()); }