aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_generics.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_generics.py')
-rw-r--r--tests/test_generics.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/test_generics.py b/tests/test_generics.py
index 17bfca2f..51004edf 100644
--- a/tests/test_generics.py
+++ b/tests/test_generics.py
@@ -547,7 +547,9 @@ class ClassA(models.Model):
class ClassASerializer(serializers.ModelSerializer):
- childs = serializers.PrimaryKeyRelatedField(many=True, source='childs')
+ childs = serializers.PrimaryKeyRelatedField(
+ many=True, queryset=ClassB.objects.all()
+ )
class Meta:
model = ClassA