diff --git a/tests/admin_views/tests.py b/tests/admin_views/tests.py
index 7c4474d3dcc..62aa236e2b7 100644
--- a/tests/admin_views/tests.py
+++ b/tests/admin_views/tests.py
@@ -1726,6 +1726,8 @@ class AdminViewPermissionsTest(TestCase):
# Now give the user permission to add but not change.
self.viewuser.user_permissions.add(get_perm(Article, get_permission_codename('add', Article._meta)))
response = self.client.get(reverse('admin:admin_views_article_add'))
+ self.assertEqual(response.context['title'], 'Add article')
+ self.assertContains(response, '
Add article | Django site admin')
self.assertContains(response, '')
post = self.client.post(reverse('admin:admin_views_article_add'), add_dict, follow=False)
self.assertEqual(post.status_code, 302)
@@ -1824,11 +1826,16 @@ class AdminViewPermissionsTest(TestCase):
# view user can view articles but not make changes.
self.client.force_login(self.viewuser)
response = self.client.get(article_changelist_url)
- self.assertEqual(response.status_code, 200)
self.assertEqual(response.context['title'], 'Select article to view')
+ self.assertContains(
+ response,
+ 'Select article to view | Django site admin',
+ )
+ self.assertContains(response, '