1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Fixed #27463 -- Fixed E741 flake8 warnings.

This commit is contained in:
Ramin Farajpour Cami
2016-11-15 02:10:28 +03:30
committed by Tim Graham
parent c7bfcd2f37
commit 0a63ef3f61
18 changed files with 90 additions and 83 deletions

View File

@@ -181,15 +181,15 @@ class WriterTests(SimpleTestCase):
"""
def safe_exec(self, string, value=None):
l = {}
d = {}
try:
exec(force_str(string), globals(), l)
exec(force_str(string), globals(), d)
except Exception as e:
if value:
self.fail("Could not exec %r (from value %r): %s" % (string.strip(), value, e))
else:
self.fail("Could not exec %r: %s" % (string.strip(), e))
return l
return d
def serialize_round_trip(self, value):
string, imports = MigrationWriter.serialize(value)