From 6ab9f4904a516cee65c10bc827a0ae773b24a637 Mon Sep 17 00:00:00 2001 From: = Date: Sat, 24 Jun 2017 21:01:07 -0600 Subject: [PATCH] test static rolls --- game_test.rb | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/game_test.rb b/game_test.rb index 1c17689..1c309b9 100644 --- a/game_test.rb +++ b/game_test.rb @@ -17,4 +17,16 @@ def test_20_rolls_of_0_is_0 assert_equal(0, @game.score, "game score wrong for 0 pins") end + def test_static_rolls_score_is_correct + (1..9).each do |pin_count| + (0..9).each do |frames| + @game.add_roll(pin_count) + @game.add_roll(0) + end + assert_equal(pin_count * 10, @game.score, "score is wrong first static test!") + @game.reset + end + end + + end