mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Added support for time zones. Thanks Luke Plant for the review. Fixed #2626.
For more information on this project, see this thread: http://groups.google.com/group/django-developers/browse_thread/thread/cf0423bbb85b1bbf git-svn-id: http://code.djangoproject.com/svn/django/trunk@17106 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -4,6 +4,7 @@ import time
|
||||
|
||||
from django.utils.dateformat import format
|
||||
from django.utils import dateformat, translation, unittest
|
||||
from django.utils.timezone import utc
|
||||
from django.utils.tzinfo import FixedOffset, LocalTimezone
|
||||
|
||||
|
||||
@@ -56,7 +57,6 @@ class DateFormatTests(unittest.TestCase):
|
||||
self.assertEqual(datetime.fromtimestamp(int(format(dt, 'U')), ltz).utctimetuple(), dt.utctimetuple())
|
||||
|
||||
def test_epoch(self):
|
||||
utc = FixedOffset(0)
|
||||
udt = datetime(1970, 1, 1, tzinfo=utc)
|
||||
self.assertEqual(format(udt, 'U'), u'0')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user