summaryrefslogtreecommitdiff
path: root/tests/admin_views
diff options
context:
space:
mode:
authorDan Stephenson <daniel.Stephenson@uk.rsagroup.com>2016-05-04 01:11:21 +0100
committerTim Graham <timograham@gmail.com>2016-05-04 09:43:24 -0400
commit1206eea11e506c4e740ba2f0c1feaa01452d804b (patch)
tree4a249148dabf248ae7b53a86625619bf9cfbe7b3 /tests/admin_views
parentad0f536e1c80e7122f03ae4746a90904a573b4b8 (diff)
Fixed #26558 -- Removed need for request context processor on admin login page.
Diffstat (limited to 'tests/admin_views')
-rw-r--r--tests/admin_views/tests.py15
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/admin_views/tests.py b/tests/admin_views/tests.py
index b1c7a29a03..281084a8a1 100644
--- a/tests/admin_views/tests.py
+++ b/tests/admin_views/tests.py
@@ -1279,7 +1279,20 @@ def get_perm(Model, perm):
return Permission.objects.get(content_type=ct, codename=perm)
-@override_settings(ROOT_URLCONF='admin_views.urls')
+@override_settings(
+ ROOT_URLCONF='admin_views.urls',
+ # Test with the admin's documented list of required context processors.
+ TEMPLATES=[{
+ 'BACKEND': 'django.template.backends.django.DjangoTemplates',
+ 'APP_DIRS': True,
+ 'OPTIONS': {
+ 'context_processors': [
+ 'django.contrib.auth.context_processors.auth',
+ 'django.contrib.messages.context_processors.messages',
+ ],
+ },
+ }],
+)
class AdminViewPermissionsTest(TestCase):
"""Tests for Admin Views Permissions."""