1
0
mirror of https://github.com/django/django.git synced 2025-11-07 07:15:35 +00:00

Fixed #26973 -- Fixed views.static.serve() crash with show_indexes enabled.

This commit is contained in:
Tim Graham
2016-08-10 11:27:03 -04:00
committed by GitHub
parent 0814566bf1
commit 1e32e1cc95
4 changed files with 9 additions and 2 deletions

View File

@@ -108,6 +108,10 @@ class StaticTests(SimpleTestCase):
response = self.client.get('/%s/non_existing_resource' % self.prefix)
self.assertEqual(404, response.status_code)
def test_index(self):
response = self.client.get('/%s/' % self.prefix)
self.assertContains(response, 'Index of /')
class StaticHelperTest(StaticTests):
"""