Beispiel #1
0
 def test_simulate_match_argument_types(self):
     with self.assertRaises(ValueError):
         match.simulate_match('2', '3')
Beispiel #2
0
 def test_simulate_match_argument_type_none(self):
     with self.assertRaises(ValueError):
         match.simulate_match(None, None)
Beispiel #3
0
 def test_simulate_match_argument_type_float(self):
     with self.assertRaises(ValueError):
         match.simulate_match(2.5, 3.7)
Beispiel #4
0
 def test_simulate_match_draw(self):
     self.assertEqual(match.simulate_match(1, 1),
                      'Match ended with draw result 1:1')
Beispiel #5
0
 def test_simulate_match_away_team_wins(self):
     self.assertEqual(match.simulate_match(2, 3),
                      'Away team wins. Match score 2:3')
Beispiel #6
0
 def test_simulate_match_home_team_wins(self):
     self.assertEqual(match.simulate_match(3, 2),
                      'Home team wins. Match score 3:2')