summaryrefslogtreecommitdiff
path: root/tests/admin_views
diff options
context:
space:
mode:
authorTim Graham <timograham@gmail.com>2017-01-04 10:12:06 -0500
committerTim Graham <timograham@gmail.com>2017-01-04 10:22:17 -0500
commit8ea541e6a297d6bcdef233871a22b5cc99a0a527 (patch)
treedfccaae357acb067415fee8585ccdf13af246263 /tests/admin_views
parentbff4abacad48eba715be64d7b15582d15bdc1fca (diff)
Refs #2856 -- Removed redundant escaping in admin's "Perhaps it was deleted?" message.
Diffstat (limited to 'tests/admin_views')
-rw-r--r--tests/admin_views/tests.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/admin_views/tests.py b/tests/admin_views/tests.py
index 706d6ec7a6..c952a9ebf2 100644
--- a/tests/admin_views/tests.py
+++ b/tests/admin_views/tests.py
@@ -249,11 +249,11 @@ class AdminViewBasicTest(AdminViewBasicTestCase):
model with an integer PK field) redirects to the index page with a
message saying the object doesn't exist.
"""
- response = self.client.get(reverse('admin:admin_views_section_change', args=('abc',)), follow=True)
+ response = self.client.get(reverse('admin:admin_views_section_change', args=(quote("abc/<b>"),)), follow=True)
self.assertRedirects(response, reverse('admin:index'))
self.assertEqual(
[m.message for m in response.context['messages']],
- ["section with ID abc doesn't exist. Perhaps it was deleted?"]
+ ["""section with ID "abc/<b>" doesn't exist. Perhaps it was deleted?"""]
)
def test_basic_edit_GET_old_url_redirect(self):
@@ -274,7 +274,7 @@ class AdminViewBasicTest(AdminViewBasicTestCase):
self.assertRedirects(response, reverse('admin:index'))
self.assertEqual(
[m.message for m in response.context['messages']],
- ["super villain with ID abc doesn't exist. Perhaps it was deleted?"]
+ ["""super villain with ID "abc" doesn't exist. Perhaps it was deleted?"""]
)
def test_basic_add_POST(self):
@@ -1801,7 +1801,7 @@ class AdminViewPermissionsTest(TestCase):
self.assertRedirects(response, reverse('admin:index'))
self.assertEqual(
[m.message for m in response.context['messages']],
- ["article with ID nonexistent doesn't exist. Perhaps it was deleted?"]
+ ["""article with ID "nonexistent" doesn't exist. Perhaps it was deleted?"""]
)
def test_history_view(self):
@@ -1849,7 +1849,7 @@ class AdminViewPermissionsTest(TestCase):
self.assertRedirects(response, reverse('admin:index'))
self.assertEqual(
[m.message for m in response.context['messages']],
- ["article with ID foo doesn't exist. Perhaps it was deleted?"]
+ ["""article with ID "foo" doesn't exist. Perhaps it was deleted?"""]
)
def test_conditionally_show_add_section_link(self):
@@ -3638,7 +3638,7 @@ class AdminCustomQuerysetTest(TestCase):
self.assertRedirects(response, reverse('admin:index'))
self.assertEqual(
[m.message for m in response.context['messages']],
- ["empty model with ID 1 doesn't exist. Perhaps it was deleted?"]
+ ["""empty model with ID "1" doesn't exist. Perhaps it was deleted?"""]
)
def test_add_model_modeladmin_defer_qs(self):