@@ -53,11 +53,6 @@ def schema_with_object_with_field_resolver(
5353 )
5454
5555
56- ObjectWithIsTypeOf = GraphQLObjectType (
57- "ObjectWithIsTypeOf" , {"f" : GraphQLField (GraphQLString )}
58- )
59-
60-
6156def describe_type_system_scalars ():
6257 def accepts_a_scalar_type_defining_serialize ():
6358 schema_with_field_type (GraphQLScalarType ("SomeScalar" , lambda : None ))
@@ -266,11 +261,6 @@ def interfaces():
266261 def accepts_a_lambda_as_an_object_field_resolver ():
267262 schema_with_object_with_field_resolver (lambda _obj , _info : {})
268263
269- def accepts_an_object_type_with_an_is_type_of_function ():
270- schema_with_field_type (
271- GraphQLObjectType ("AnotherObject" , {"f" : GraphQLField (GraphQLString )})
272- )
273-
274264 def rejects_an_object_type_field_with_undefined_config ():
275265 undefined_field = cast (GraphQLField , None )
276266 obj_type = GraphQLObjectType ("SomeObject" , {"f" : undefined_field })
@@ -394,30 +384,6 @@ def accepts_an_interface_type_defining_resolve_type():
394384 schema .query_type .fields ["field" ].type .interfaces [0 ] is AnotherInterfaceType
395385 )
396386
397- def accepts_an_interface_with_implementing_type_defining_is_type_of ():
398- InterfaceTypeWithoutResolveType = GraphQLInterfaceType (
399- "InterfaceTypeWithoutResolveType" , {"f" : GraphQLField (GraphQLString )}
400- )
401-
402- assert schema_with_field_type (
403- GraphQLObjectType (
404- "SomeObject" ,
405- {"f" : GraphQLField (GraphQLString )},
406- [InterfaceTypeWithoutResolveType ],
407- )
408- )
409-
410- def accepts_interface_type_with_resolve_type_and_is_type_of_in_implementation ():
411- AnotherInterfaceType = GraphQLInterfaceType (
412- "AnotherInterfaceType" , {"f" : GraphQLField (GraphQLString )}
413- )
414-
415- assert schema_with_field_type (
416- GraphQLObjectType (
417- "SomeObject" , {"f" : GraphQLField (GraphQLString )}, [AnotherInterfaceType ]
418- )
419- )
420-
421387 def rejects_an_interface_type_with_an_incorrect_type_for_resolve_type ():
422388 with raises (TypeError ) as exc_info :
423389 # noinspection PyTypeChecker
@@ -442,11 +408,6 @@ def allows_a_thunk_for_union_member_types():
442408 def accepts_a_union_type_defining_resolve_type ():
443409 assert schema_with_field_type (GraphQLUnionType ("SomeUnion" , [ObjectType ]))
444410
445- def accepts_a_union_of_object_types_defining_is_type_of ():
446- assert schema_with_field_type (
447- GraphQLUnionType ("SomeUnion" , [ObjectWithIsTypeOf ])
448- )
449-
450411 def accepts_a_union_type_with_list_types ():
451412 assert schema_with_field_type (GraphQLUnionType ("SomeUnion" , [ObjectType ]))
452413
@@ -463,9 +424,7 @@ def accepts_a_union_type_without_types():
463424 def rejects_an_interface_type_with_an_incorrect_type_for_resolve_type ():
464425 with raises (TypeError ) as exc_info :
465426 # noinspection PyTypeChecker
466- schema_with_field_type (
467- GraphQLUnionType ("SomeUnion" , [ObjectWithIsTypeOf ], resolve_type = {})
468- )
427+ schema_with_field_type (GraphQLUnionType ("SomeUnion" , [], resolve_type = {}))
469428 msg = str (exc_info .value )
470429 assert msg == (
471430 "SomeUnion must provide 'resolve_type' as a function, but got: {}."
0 commit comments