mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-08-07 22:04:48 +03:00
flake
This commit is contained in:
parent
09aff6daeb
commit
25fee8e07b
|
@ -1295,7 +1295,7 @@ class RecursiveField(Field):
|
||||||
|
|
||||||
def __init__(self, **kwargs):
|
def __init__(self, **kwargs):
|
||||||
field_kwargs = dict(
|
field_kwargs = dict(
|
||||||
(key, value)
|
(key, kwargs[key])
|
||||||
for key in kwargs
|
for key in kwargs
|
||||||
if key in inspect.getargspec(Field.__init__)
|
if key in inspect.getargspec(Field.__init__)
|
||||||
)
|
)
|
||||||
|
@ -1329,6 +1329,7 @@ class RecursiveField(Field):
|
||||||
else:
|
else:
|
||||||
real_dict[name] = value
|
real_dict[name] = value
|
||||||
|
|
||||||
|
|
||||||
class SerializerMethodField(Field):
|
class SerializerMethodField(Field):
|
||||||
"""
|
"""
|
||||||
A read-only field that get its representation from calling a method on the
|
A read-only field that get its representation from calling a method on the
|
||||||
|
|
|
@ -358,6 +358,7 @@ class TestRecursiveField:
|
||||||
assert serializer.validated_data == value, \
|
assert serializer.validated_data == value, \
|
||||||
'deserialized data does not match input'
|
'deserialized data does not match input'
|
||||||
|
|
||||||
|
|
||||||
# Tests for field input and output values.
|
# Tests for field input and output values.
|
||||||
# ----------------------------------------
|
# ----------------------------------------
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user