diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/admin_views/test_nav_sidebar.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/admin_views/test_nav_sidebar.py b/tests/admin_views/test_nav_sidebar.py index 01cd4cfee7..b3d4955b19 100644 --- a/tests/admin_views/test_nav_sidebar.py +++ b/tests/admin_views/test_nav_sidebar.py @@ -77,6 +77,14 @@ class AdminSidebarTests(TestCase): self.assertContains(response, '<a href="%s">Users</a>' % url) self.assertNotContains(response, 'aria-current') + @override_settings(DEBUG=True) + def test_included_app_list_template_context_fully_set(self): + # All context variables should be set when rendering the sidebar. + url = reverse('test_with_sidebar:auth_user_changelist') + with self.assertRaisesMessage(AssertionError, 'no logs'): + with self.assertLogs('django.template', 'DEBUG'): + self.client.get(url) + @override_settings(ROOT_URLCONF='admin_views.test_nav_sidebar') class SeleniumTests(AdminSeleniumTestCase): |
