Opened 15 years ago

Closed 15 years ago

#12123 closed (fixed)

dateformat tests fail on first of the month if in GMT+ timezone

Reported by: Russell Keith-Magee Owned by: nobody
Component: Uncategorized Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The dateformat tests set the system timezone to Europe/Copenhagen, but doesn't revert this setting.

As a result, the generic date_archive view test fails during the morning of the first of the month because datetime.now() returns the date in Copenhagen, not the date in settings.TIMEZONE.

Change History (4)

comment:1 by Russell Keith-Magee, 15 years ago

Resolution: fixed
Status: newclosed

(In [11693]) Fixed #12123 -- Refactored dateformat tests to use unittest. This is needed so that we have a reliable teardown that can reset the timezone at the end of the test.

comment:2 by Russell Keith-Magee, 15 years ago

(In [11694]) [1.1.X] Fixed #12123 -- Refactored dateformat tests to use unittest. This is needed so that we have a reliable teardown that can reset the timezone at the end of the test.

Backport of r11693 from trunk.

comment:3 by Russell Keith-Magee, 15 years ago

Resolution: fixed
Status: closedreopened

Oops - there's a dependency on the dateformat tests in utils.dateformat. A fix is on the way.

comment:4 by Russell Keith-Magee, 15 years ago

Resolution: fixed
Status: reopenedclosed

(In [11696]) [1.1.X] Fixed #12123 -- Updated the utils.dateformat test to be a unittest too, due to a dependency on the old dateformat test.

Backport of r11695 from trunk.

Note: See TracTickets for help on using tickets.
Back to Top