mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-07-28 00:49:49 +03:00
Fixed lint issues
This commit is contained in:
parent
d3a9259d4d
commit
d9cddb4428
|
@ -77,11 +77,11 @@ class TestFieldMapping(TestCase):
|
||||||
(serializers.ListField(child=serializers.ChoiceField(choices=[
|
(serializers.ListField(child=serializers.ChoiceField(choices=[
|
||||||
(1, 'One'), ('a', 'Choice A'), (1.1, 'First'), (1.1, 'First'), (1, 'One'), ('a', 'Choice A'), (1, 'One')
|
(1, 'One'), ('a', 'Choice A'), (1.1, 'First'), (1.1, 'First'), (1, 'One'), ('a', 'Choice A'), (1, 'One')
|
||||||
])),
|
])),
|
||||||
{'items': {'enum': [1, 'a', 1.1]}, 'type': 'array'}),
|
{'items': {'enum': [1, 'a', 1.1]}, 'type': 'array'}),
|
||||||
(serializers.ListField(child=serializers.ChoiceField(choices=[
|
(serializers.ListField(child=serializers.ChoiceField(choices=[
|
||||||
(1, 'One'), (2, 'Two'), (3, 'Three'), (2, 'Two'), (3, 'Three'), (1, 'One'),
|
(1, 'One'), (2, 'Two'), (3, 'Three'), (2, 'Two'), (3, 'Three'), (1, 'One'),
|
||||||
])),
|
])),
|
||||||
{'items': {'enum': [1, 2, 3], 'type': 'integer'}, 'type': 'array'}),
|
{'items': {'enum': [1, 2, 3], 'type': 'integer'}, 'type': 'array'}),
|
||||||
(serializers.IntegerField(min_value=2147483648),
|
(serializers.IntegerField(min_value=2147483648),
|
||||||
{'type': 'integer', 'minimum': 2147483648, 'format': 'int64'}),
|
{'type': 'integer', 'minimum': 2147483648, 'format': 'int64'}),
|
||||||
(NestedSerializer(),
|
(NestedSerializer(),
|
||||||
|
@ -545,8 +545,8 @@ class TestOperationIntrospection(TestCase):
|
||||||
'o2': reused_object,
|
'o2': reused_object,
|
||||||
}
|
}
|
||||||
assert (
|
assert (
|
||||||
renderer.render(data) == b'o1:\n test: test\no2:\n test: test\n' or
|
renderer.render(data) == b'o1:\n test: test\no2:\n test: test\n' or
|
||||||
renderer.render(data) == b'o2:\n test: test\no1:\n test: test\n' # py <= 3.5
|
renderer.render(data) == b'o2:\n test: test\no1:\n test: test\n' # py <= 3.5
|
||||||
)
|
)
|
||||||
|
|
||||||
def test_serializer_filefield(self):
|
def test_serializer_filefield(self):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user