コード例 #1
0
 def test_two_gutters_frame():
     two_gutters = [[0,0]]
     result = bowling_game.calculate_standard_frame(two_gutters)
     assert result == 0
コード例 #2
0
 def test_spare_frame():
     frame = [[8,2],[4],[]]
     result = bowling_game.calculate_standard_frame(frame)
     assert result == 14
コード例 #3
0
 def test_double_strike_frame():
     frame = [[10],[10], [7,3]]
     result = bowling_game.calculate_standard_frame(frame)
     assert result == 27
コード例 #4
0
 def test_triple_strike_frame():
     frame = [[10],[10],[10,8]]
     result = bowling_game.calculate_standard_frame(frame)
     assert result == 30
コード例 #5
0
 def test_strike_frame():
     frame = [[10],[2,2]]
     result = bowling_game.calculate_standard_frame(frame)
     assert result == 14
コード例 #6
0
 def test_two_gutters_frame():
     frame = [[0,0],[1]]
     result = bowling_game.calculate_standard_frame(frame)
     assert result == 0
コード例 #7
0
 def test_spare_frame():
     spare = [[2,8],[3,5]]
     result = bowling_game.calculate_standard_frame(spare)
     assert result == 13
コード例 #8
0
 def test_doublestrike_frame():
     double_strike = [[10],[10], [2,6]]
     result = bowling_game.calculate_standard_frame(double_strike)
     assert result == 22
コード例 #9
0
 def test_strike_frame():
     strike = [[10],[3,3],[10]]
     result = bowling_game.calculate_standard_frame(strike)
     assert result == 16