def test_tie_race_winner_flags(self): "Winner flag should not be assigned to any candidate in a tie race" results = summarize(self.SAMPLE_RESULTS) race = results["President"] for cand in race["candidates"]: self.assertEqual(cand["winner"], "")
def setUp(self): results = summarize(self.SAMPLE_RESULTS) self.race = results["President"]
def setUp(self): results = summarize(self.SAMPLE_RESULTS) self.race = results['President']
def test_tie_race_winner_flags(self): "Winner flag should not be assigned to any candidate in a tie race" results = summarize(self.SAMPLE_RESULTS) race = results['President'] for cand in race['candidates']: self.assertEqual(cand['winner'], '')