mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-10 19:56:59 +03:00
Fix code style
This commit is contained in:
parent
4345894445
commit
66b2c6149e
|
@ -1136,13 +1136,13 @@ class Test5004UniqueChoiceField(TestCase):
|
|||
assert not serializer.is_valid()
|
||||
assert serializer.errors == {'name': ['unique choice model with this name already exists.']}
|
||||
|
||||
|
||||
class TestFieldSource(TestCase):
|
||||
|
||||
def test_named_field_source(self):
|
||||
class TestSerializer(serializers.ModelSerializer):
|
||||
|
||||
class Meta:
|
||||
model = RegularFieldsModel
|
||||
model = RegularFieldsModel
|
||||
fields = ('number_field',)
|
||||
extra_kwargs = {
|
||||
'number_field': {
|
||||
|
@ -1156,4 +1156,3 @@ class TestFieldSource(TestCase):
|
|||
""")
|
||||
self.maxDiff = None
|
||||
self.assertEqual(unicode_repr(TestSerializer()), expected)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user