Ticket #27637: 27637.diff

File 27637.diff, 732 bytes (added by Mariusz Felisiak, 8 years ago)
  • tests/utils_tests/test_timesince.py

    diff --git a/tests/utils_tests/test_timesince.py b/tests/utils_tests/test_timesince.py
    index a410032..68e48f4 100644
    a b class TimesinceTests(unittest.TestCase):  
    105105        self.assertEqual(timeuntil(today - self.oneday, today), '0\xa0minutes')
    106106        self.assertEqual(timeuntil(today + self.oneweek, today), '1\xa0week')
    107107
     108    def test_leap_year(self):
     109        start_date = datetime.date(2016, 12, 25)
     110        self.assertEqual(timeuntil(start_date + self.oneweek, start_date), '1\xa0week')
     111
    108112    def test_naive_datetime_with_tzinfo_attribute(self):
    109113        class naive(datetime.tzinfo):
    110114            def utcoffset(self, dt):
Back to Top