mirror of
https://github.com/django/django.git
synced 2025-08-04 10:59:45 +00:00
Fixed E128, E741 flake8 warnings.
This commit is contained in:
parent
e6ec76d245
commit
0668164b4a
11 changed files with 94 additions and 78 deletions
|
@ -72,7 +72,7 @@ class TestFindStatic(TestDefaults, CollectionTestCase):
|
|||
findstatic returns all candidate files if run without --first and -v1.
|
||||
"""
|
||||
result = call_command('findstatic', 'test/file.txt', verbosity=1, stdout=StringIO())
|
||||
lines = [l.strip() for l in result.split('\n')]
|
||||
lines = [line.strip() for line in result.split('\n')]
|
||||
self.assertEqual(len(lines), 3) # three because there is also the "Found <file> here" line
|
||||
self.assertIn('project', lines[1])
|
||||
self.assertIn('apps', lines[2])
|
||||
|
@ -82,7 +82,7 @@ class TestFindStatic(TestDefaults, CollectionTestCase):
|
|||
findstatic returns all candidate files if run without --first and -v0.
|
||||
"""
|
||||
result = call_command('findstatic', 'test/file.txt', verbosity=0, stdout=StringIO())
|
||||
lines = [l.strip() for l in result.split('\n')]
|
||||
lines = [line.strip() for line in result.split('\n')]
|
||||
self.assertEqual(len(lines), 2)
|
||||
self.assertIn('project', lines[0])
|
||||
self.assertIn('apps', lines[1])
|
||||
|
@ -93,7 +93,7 @@ class TestFindStatic(TestDefaults, CollectionTestCase):
|
|||
Also, test that findstatic returns the searched locations with -v2.
|
||||
"""
|
||||
result = call_command('findstatic', 'test/file.txt', verbosity=2, stdout=StringIO())
|
||||
lines = [l.strip() for l in result.split('\n')]
|
||||
lines = [line.strip() for line in result.split('\n')]
|
||||
self.assertIn('project', lines[1])
|
||||
self.assertIn('apps', lines[2])
|
||||
self.assertIn("Looking in the following locations:", lines[3])
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue