def test_days_to_weekday_returns_correct_number_of_days(self): self.assertEqual(dateutils.days_to_weekday(self.thursday, 4), 1) self.assertEqual(dateutils.days_to_weekday(self.thursday, 5), 2) self.assertEqual(dateutils.days_to_weekday(self.thursday, 6), 3) self.assertEqual(dateutils.days_to_weekday(self.thursday, 0), 4) self.assertEqual(dateutils.days_to_weekday(self.thursday, 1), 5) self.assertEqual(dateutils.days_to_weekday(self.thursday, 2), 6) self.assertEqual(dateutils.days_to_weekday(self.thursday, 3), 7)
def test_days_to_weekday_returns_int(self): self.assertIsInstance(dateutils.days_to_weekday(self.thursday, 0), int)