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

Refs #23919 -- Replaced super(ClassName, self) with super().

This commit is contained in:
chillaranand
2017-01-21 18:43:44 +05:30
committed by Tim Graham
parent dc165ec8e5
commit d6eaf7c018
339 changed files with 1221 additions and 1296 deletions

View File

@@ -216,7 +216,7 @@ class ModelFormBaseTest(TestCase):
fields = '__all__'
def __init__(self, *args, **kwargs):
super(FormForTestingIsValid, self).__init__(*args, **kwargs)
super().__init__(*args, **kwargs)
self.fields['character'].required = False
char = Character.objects.create(username='user',
@@ -245,7 +245,7 @@ class ModelFormBaseTest(TestCase):
fields = '__all__'
def __init__(self, *args, **kwargs):
super(AwardForm, self).__init__(*args, **kwargs)
super().__init__(*args, **kwargs)
self.fields['character'].required = False
character = Character.objects.create(username='user', last_action=datetime.datetime.today())
@@ -2947,7 +2947,7 @@ class LocalizedModelFormTest(TestCase):
class CustomMetaclass(ModelFormMetaclass):
def __new__(cls, name, bases, attrs):
new = super(CustomMetaclass, cls).__new__(cls, name, bases, attrs)
new = super().__new__(cls, name, bases, attrs)
new.base_fields = {}
return new