Fixed #18269 -- Applied unicode_literals for Python 3 compatibility.

Thanks Vinay Sajip for the support of his django3 branch and
Jannis Leidel for the review.
This commit is contained in:
Claude Paroz 2012-06-07 18:08:47 +02:00
parent 706fd9adc0
commit 4a103086d5
401 changed files with 6647 additions and 6157 deletions

View file

@ -1,3 +1,5 @@
from __future__ import unicode_literals
import datetime
from django.utils import feedgenerator, tzinfo, unittest
@ -13,7 +15,7 @@ class FeedgeneratorTest(unittest.TestCase):
"""
self.assertEqual(
feedgenerator.get_tag_uri('http://example.org/foo/bar#headline', datetime.date(2004, 10, 25)),
u'tag:example.org,2004-10-25:/foo/bar/headline')
'tag:example.org,2004-10-25:/foo/bar/headline')
def test_get_tag_uri_with_port(self):
"""
@ -22,7 +24,7 @@ class FeedgeneratorTest(unittest.TestCase):
"""
self.assertEqual(
feedgenerator.get_tag_uri('http://www.example.org:8000/2008/11/14/django#headline', datetime.datetime(2008, 11, 14, 13, 37, 0)),
u'tag:www.example.org,2008-11-14:/2008/11/14/django/headline')
'tag:www.example.org,2008-11-14:/2008/11/14/django/headline')
def test_rfc2822_date(self):
"""