Beispiel #1
0
 def test_one_skittle(self):
     self.assertEqual(compute_bowling_score([5]), 5)
Beispiel #2
0
 def test_spare_and_strike(self):
     self.assertEqual(
         compute_bowling_score([10, 3, 7, 5, 3, 5, 5, 7, 2, 5]), 74)
Beispiel #3
0
 def test_no_skittle(self):
     self.assertEqual(compute_bowling_score([]), 0)
Beispiel #4
0
 def test_multi_strike(self):
     self.assertEqual(compute_bowling_score([10, 10, 10, 10]), 90)
Beispiel #5
0
 def test_strike(self):
     self.assertEqual(compute_bowling_score([10, 5, 2]), 24)
Beispiel #6
0
 def test_multiple_spare(self):
     self.assertEqual(compute_bowling_score([5, 5, 2, 8, 5]), 32)
Beispiel #7
0
 def test_spare(self):
     self.assertEqual(compute_bowling_score([5, 5, 2]), 14)
Beispiel #8
0
 def test_multiple_skittle(self):
     self.assertEqual(compute_bowling_score([5, 3, 2, 5, 4, 5]), 24)