コード例 #1
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_one_skittle(self):
     self.assertEqual(compute_bowling_score([5]), 5)
コード例 #2
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_spare_and_strike(self):
     self.assertEqual(
         compute_bowling_score([10, 3, 7, 5, 3, 5, 5, 7, 2, 5]), 74)
コード例 #3
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_no_skittle(self):
     self.assertEqual(compute_bowling_score([]), 0)
コード例 #4
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_multi_strike(self):
     self.assertEqual(compute_bowling_score([10, 10, 10, 10]), 90)
コード例 #5
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_strike(self):
     self.assertEqual(compute_bowling_score([10, 5, 2]), 24)
コード例 #6
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_multiple_spare(self):
     self.assertEqual(compute_bowling_score([5, 5, 2, 8, 5]), 32)
コード例 #7
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_spare(self):
     self.assertEqual(compute_bowling_score([5, 5, 2]), 14)
コード例 #8
0
ファイル: test.py プロジェクト: ehrakis/matrix.py
 def test_multiple_skittle(self):
     self.assertEqual(compute_bowling_score([5, 3, 2, 5, 4, 5]), 24)