From 4f955cf996557c24aee31f880dc5bab8eb54bc1d Mon Sep 17 00:00:00 2001 From: Andreas Kloeckner Date: Sun, 7 Oct 2018 14:56:11 -0500 Subject: [PATCH] Fix test_post_success_starting_ordinal_specified for daylight savings --- tests/test_calendar.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/test_calendar.py b/tests/test_calendar.py index 51380624..7e186f63 100644 --- a/tests/test_calendar.py +++ b/tests/test_calendar.py @@ -142,7 +142,8 @@ class CreateRecurringEventsTest(SingleCourseTestMixin, t = evt.time continue else: - self.assertEqual(evt.time - t, datetime.timedelta(weeks=1)) + self.assertTrue(evt.time - t <= datetime.timedelta(weeks=1, hours=1)) + self.assertTrue(evt.time - t >= datetime.timedelta(weeks=1)) t = evt.time def test_post_success_starting_ordinal_not_specified(self): -- GitLab