diff options
| author | Luke Plant <L.Plant.98@cantab.net> | 2011-01-24 20:35:46 +0000 |
|---|---|---|
| committer | Luke Plant <L.Plant.98@cantab.net> | 2011-01-24 20:35:46 +0000 |
| commit | 42c31f6bf036efd93c0311bc1f524b1553c20489 (patch) | |
| tree | 1c3a2d35175278c33d969c4cb8ff89ea32823f1c /tests | |
| parent | 09a63632c5072695d3b3293a046c197ea3c3299a (diff) | |
Rationalised CompatCookie/SimpleCookie into single SimpleCookie class with all fixes.
Since upstream Python has fixed the encoding bug (see
http://bugs.python.org/issue9824), we don't want a separate class for this
bug fix, or several layers for the different fixes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15298 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/regressiontests/httpwrappers/tests.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/regressiontests/httpwrappers/tests.py b/tests/regressiontests/httpwrappers/tests.py index b983bca8ab..69b052f5cd 100644 --- a/tests/regressiontests/httpwrappers/tests.py +++ b/tests/regressiontests/httpwrappers/tests.py @@ -1,7 +1,7 @@ import copy import pickle -from django.http import QueryDict, HttpResponse, CompatCookie, BadHeaderError +from django.http import QueryDict, HttpResponse, SimpleCookie, BadHeaderError from django.utils import unittest class QueryDictTests(unittest.TestCase): @@ -250,7 +250,7 @@ class CookieTests(unittest.TestCase): # Python 2.4 compatibility note: Python 2.4's cookie implementation # always returns Set-Cookie headers terminating in semi-colons. # That's not the bug this test is looking for, so ignore it. - c = CompatCookie() + c = SimpleCookie() c['test'] = "An,awkward;value" self.assert_(";" not in c.output().rstrip(';')) # IE compat self.assert_("," not in c.output().rstrip(';')) # Safari compat @@ -259,9 +259,9 @@ class CookieTests(unittest.TestCase): """ Test that we can still preserve semi-colons and commas """ - c = CompatCookie() + c = SimpleCookie() c['test'] = "An,awkward;value" - c2 = CompatCookie() + c2 = SimpleCookie() c2.load(c.output()) self.assertEqual(c['test'].value, c2['test'].value) @@ -269,8 +269,8 @@ class CookieTests(unittest.TestCase): """ Test that we haven't broken normal encoding """ - c = CompatCookie() + c = SimpleCookie() c['test'] = "\xf0" - c2 = CompatCookie() + c2 = SimpleCookie() c2.load(c.output()) self.assertEqual(c['test'].value, c2['test'].value) |
