summaryrefslogtreecommitdiff
path: root/tests/regressiontests
diff options
context:
space:
mode:
authorLuke Plant <L.Plant.98@cantab.net>2010-09-21 19:32:22 +0000
committerLuke Plant <L.Plant.98@cantab.net>2010-09-21 19:32:22 +0000
commit9d6eeeec39f834ad480778ba7aa4ece01c6f7aff (patch)
tree4230033440099834c7b736387addee48110dc0ea /tests/regressiontests
parent11aee35a9fb72c470364a93186823a327d6840bb (diff)
Fixed #12019 - backwards compatibility issues with cache_page decorator.
Thanks to rokclimb15 for the report, and j4mie/rokclimb15 for the patches. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13864 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests/regressiontests')
-rw-r--r--tests/regressiontests/decorators/tests.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/regressiontests/decorators/tests.py b/tests/regressiontests/decorators/tests.py
index 7855fef638..ea2e10e965 100644
--- a/tests/regressiontests/decorators/tests.py
+++ b/tests/regressiontests/decorators/tests.py
@@ -112,6 +112,10 @@ class DecoratorsTest(TestCase):
self.assertEqual(my_view_cached(HttpRequest()), "response")
my_view_cached2 = cache_page(my_view, 123, key_prefix="test")
self.assertEqual(my_view_cached2(HttpRequest()), "response")
+ my_view_cached3 = cache_page(my_view)
+ self.assertEqual(my_view_cached3(HttpRequest()), "response")
+ my_view_cached4 = cache_page()(my_view)
+ self.assertEqual(my_view_cached4(HttpRequest()), "response")
# For testing method_decorator, a decorator that assumes a single argument.