public void When_rolling_to_start_the_game()
        {
            var roll = new Roll(5);

            game = new Game();

            game.AddRoll(roll);
        }
        public void When_rolling_a_strike_to_start_the_game()
        {
            Roll strike = new Roll(10);

            game = new Game();

            game.AddRoll(strike);
        }
        public void Rolling_3_strikes()
        {
            game = new Game();

            game.AddRoll(new Roll(10));
            game.AddRoll(new Roll(10));
            game.AddRoll(new Roll(10));
        }
        public void Rolling_20_incomplete_rolls()
        {
            game = new Game();

            for (int i = 0; i < 20; i++)
            {
                game.AddRoll(new Roll(2));
            }
        }
        public void When_rolling_to_start_the_game()
        {
            var miss = new Roll(3);
            var spare = new Roll(7);

            game = new Game();

            game.AddRoll(miss);
            game.AddRoll(spare);
        }
        public void Rolling_3_spares()
        {
            game = new Game();

            game.AddRoll(new Roll(6));
            game.AddRoll(new Roll(4));

            game.AddRoll(new Roll(5));
            game.AddRoll(new Roll(5));

            game.AddRoll(new Roll(8));
            game.AddRoll(new Roll(2));
        }
Пример #7
0
 public void SetUp()
 {
     game = new Game();
 }
Пример #8
0
 public void Score_ShouldReturn1IfRolledCalledWith1Pins()
 {
     var game = new Game();
     game.Roll(1);
     Assert.Equal(1, game.Score());
 }
Пример #9
0
 public void Score_ShouldReturn0IfRollNeverCalled()
 {
     var game = new Game();
     Assert.Equal(0, game.Score());
 }