Skip to content

Commit

Permalink
test 9 spare rolls
Browse files Browse the repository at this point in the history
  • Loading branch information
= committed Jun 25, 2017
1 parent 74a5395 commit b7e1e3e
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions game_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -62,4 +62,18 @@ def test_one_spare
assert_equal(20, @game.score, "simple spare and gutters wrong")
end

def test_9_spares
(0..8).each do |frame|
@game.add_roll(5)
@game.add_roll(5)
end
@game.add_roll(5)
@game.add_roll(0)

assert_equal(140, @game.score, "9 spares and a 5 wrong")
end




end

0 comments on commit b7e1e3e

Please sign in to comment.