diff --git a/django/contrib/admin/static/admin/css/changelists.css b/django/contrib/admin/static/admin/css/changelists.css
index 4eab7604d0..17690a3478 100644
--- a/django/contrib/admin/static/admin/css/changelists.css
+++ b/django/contrib/admin/static/admin/css/changelists.css
@@ -166,6 +166,8 @@
#changelist-filter a {
display: block;
color: #999;
+ text-overflow: ellipsis;
+ overflow-x: hidden;
}
#changelist-filter li.selected {
diff --git a/django/contrib/admin/templates/admin/filter.html b/django/contrib/admin/templates/admin/filter.html
index d4a61a1513..cd88652a62 100644
--- a/django/contrib/admin/templates/admin/filter.html
+++ b/django/contrib/admin/templates/admin/filter.html
@@ -3,6 +3,6 @@
diff --git a/tests/admin_views/tests.py b/tests/admin_views/tests.py
index f7427f7da0..2886c94bd5 100644
--- a/tests/admin_views/tests.py
+++ b/tests/admin_views/tests.py
@@ -592,7 +592,7 @@ class AdminViewBasicTest(AdminViewBasicTestCase):
for value in params['values']:
query_string = urlencode({filter_path: value})
# ensure filter link exists
- self.assertContains(response, '' % query_string)
+ self.assertContains(response, '')
- self.assertContains(response, 'Horizontal', msg_prefix=fail_msg, html=True)
- self.assertContains(response, 'Vertical', msg_prefix=fail_msg, html=True)
+ self.assertContains(
+ response, 'Horizontal',
+ msg_prefix=fail_msg, html=True
+ )
+ self.assertContains(
+ response, 'Vertical',
+ msg_prefix=fail_msg, html=True
+ )
def test_change_list_null_boolean_display(self):
Post.objects.create(public=None)