Closed sbaechler closed 9 years ago
Yes. Btw, elephantblog_archive_months
is already being tested, and both codepaths are run by Travis CI. We did not see the problem earlier because USE_TZ
is set to False
in the testsuite.
.dates()
returns naive datetimes, which in turn makes |date
handle those dates incorrectly. The naive datetimes were seen as UTC, while the installation's time zone was America/Chicago. This also explains why we always got the previous month (because america's wall clock is behind UTC).
The test suite now tests what it is supposed to:
Achso, danke.
The fix in https://github.com/feincms/feincms-elephantblog/commit/1823c14ae1cca21a9f3a49badb377d38259cf76c needs unit tests.