From fa57c2229a84febecafbf74bbc79d127b45b312d Mon Sep 17 00:00:00 2001 From: Arthur Date: Tue, 23 Apr 2024 10:05:18 -0700 Subject: [PATCH] 15809 fix tests --- netbox/utilities/testing/api.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/netbox/utilities/testing/api.py b/netbox/utilities/testing/api.py index a30235d93..4802c3ffe 100644 --- a/netbox/utilities/testing/api.py +++ b/netbox/utilities/testing/api.py @@ -469,6 +469,9 @@ class APIViewTestCases: elif type(field.type) is StrawberryUnion: # this would require a fragment query continue + elif type(field.type) is StrawberryOptional and type(field.type.of_type) is StrawberryUnion: + # this would require a fragment query + continue elif type(field.type) is StrawberryOptional and type(field.type.of_type) is LazyType: fields_string += f'{field.name} {{ id }}\n' elif hasattr(field, 'is_relation') and field.is_relation: