summaryrefslogtreecommitdiff
path: root/tests/admin_views/tests.py
diff options
context:
space:
mode:
authorBerker Peksag <berker.peksag@gmail.com>2014-11-29 08:19:59 +0200
committerTim Graham <timograham@gmail.com>2014-11-29 10:31:09 -0500
commitc8dcded930a1d0ee5688ae2c2eeb8c33d942009f (patch)
tree319e9868f808bca0cef788330a33225f42a3c9b7 /tests/admin_views/tests.py
parent3131e9cef5f0a96f4fe667b0b1626c238153d1f1 (diff)
Fixed #17890 -- Added an extra_context parameter to AdminSite.password_change().
Diffstat (limited to 'tests/admin_views/tests.py')
-rw-r--r--tests/admin_views/tests.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/admin_views/tests.py b/tests/admin_views/tests.py
index f55bcacd78..6313fdfd08 100644
--- a/tests/admin_views/tests.py
+++ b/tests/admin_views/tests.py
@@ -1012,6 +1012,12 @@ class CustomModelAdminTest(AdminViewBasicTestCase):
self.assertTemplateUsed(response, 'custom_admin/password_change_form.html')
self.assertContains(response, 'Hello from a custom password change form template')
+ def test_custom_admin_site_password_change_with_extra_context(self):
+ response = self.client.get('/test_admin/admin2/password_change/')
+ self.assertIsInstance(response, TemplateResponse)
+ self.assertTemplateUsed(response, 'custom_admin/password_change_form.html')
+ self.assertContains(response, 'eggs')
+
def test_custom_admin_site_password_change_done_template(self):
response = self.client.get('/test_admin/admin2/password_change/done/')
self.assertIsInstance(response, TemplateResponse)