mirror of
https://github.com/django/django.git
synced 2025-10-24 22:26:08 +00:00
Fixed #18013 -- Use the new 'as' syntax for exceptions.
Thanks Clueless for the initial patch. Note that unittest has been purposely left out (external package only used by Python 2.6).
This commit is contained in:
@@ -44,7 +44,7 @@ class BasicFieldTests(test.TestCase):
|
||||
nullboolean = NullBooleanModel(nbfield=None)
|
||||
try:
|
||||
nullboolean.full_clean()
|
||||
except ValidationError, e:
|
||||
except ValidationError as e:
|
||||
self.fail("NullBooleanField failed validation with value of None: %s" % e.messages)
|
||||
|
||||
def test_field_repr(self):
|
||||
|
||||
Reference in New Issue
Block a user