#NEWLINE# def test_builds_a_schema_with_an_input_object( ) : #NEWLINE# #INDENT# AddressType = GraphQLInputObjectType ( name = 'Address' , description = 'An input address' , fields = OrderedDict ( [ ( 'street' , GraphQLInputObjectField ( GraphQLNonNull ( GraphQLString ) , description = 'What street is this address?' ) ) , ( 'city' , GraphQLInputObjectField ( GraphQLNonNull ( GraphQLString ) , description = 'The city the address is within?' ) ) , ( 'country' , GraphQLInputObjectField ( GraphQLString , description = 'The country (blank will assume USA).' , default_value = 'USA' ) ) ] ) ) #NEWLINE# schema = GraphQLSchema ( query = GraphQLObjectType ( name = 'HasInputObjectFields' , fields = { #NEWLINE# #INDENT# 'geocode' : GraphQLField ( description = 'Get a geocode from an address' , type = GraphQLString , args = { #NEWLINE# #INDENT# 'address' : GraphQLArgument ( description = 'The address to lookup' , type = AddressType ) , #NEWLINE# #UNINDENT# } ) , #NEWLINE# #UNINDENT# } ) ) #NEWLINE# _test_schema ( schema )