@@ -29,26 +29,35 @@ class RootValue:
2929 schema = _test_schema (GraphQLField (GraphQLString )),
3030 source = "{ test }" ,
3131 root_value = RootValue (),
32- ) == ({"test" : "testValue" }, None ,)
32+ ) == (
33+ {"test" : "testValue" },
34+ None ,
35+ )
3336
3437 def default_function_accesses_keys_of_dict ():
3538 root_value = {"test" : "testValue" }
3639
37- assert graphql_sync (
38- schema = _test_schema (GraphQLField (GraphQLString )),
39- source = "{ test }" ,
40- root_value = root_value ,
41- ) == ({"test" : "testValue" }, None )
40+ assert (
41+ graphql_sync (
42+ schema = _test_schema (GraphQLField (GraphQLString )),
43+ source = "{ test }" ,
44+ root_value = root_value ,
45+ )
46+ == ({"test" : "testValue" }, None )
47+ )
4248
4349 def default_function_accesses_keys_of_chain_map ():
4450 # use a mapping that is not a subclass of dict
4551 root_value = ChainMap ({"test" : "testValue" })
4652
47- assert graphql_sync (
48- schema = _test_schema (GraphQLField (GraphQLString )),
49- source = "{ test }" ,
50- root_value = root_value ,
51- ) == ({"test" : "testValue" }, None )
53+ assert (
54+ graphql_sync (
55+ schema = _test_schema (GraphQLField (GraphQLString )),
56+ source = "{ test }" ,
57+ root_value = root_value ,
58+ )
59+ == ({"test" : "testValue" }, None )
60+ )
5261
5362 def default_function_calls_methods ():
5463 class RootValue :
@@ -61,7 +70,10 @@ def test(self, _info):
6170 schema = _test_schema (GraphQLField (GraphQLString )),
6271 source = "{ test }" ,
6372 root_value = RootValue (),
64- ) == ({"test" : "secretValue" }, None ,)
73+ ) == (
74+ {"test" : "secretValue" },
75+ None ,
76+ )
6577
6678 def default_function_passes_args_and_context ():
6779 class Adder :
@@ -90,7 +102,10 @@ class ContextValue:
90102 source = source ,
91103 root_value = root_value ,
92104 context_value = context_value ,
93- ) == ({"test" : 789 }, None ,)
105+ ) == (
106+ {"test" : 789 },
107+ None ,
108+ )
94109
95110 def uses_provided_resolve_function ():
96111 schema = _test_schema (
@@ -114,7 +129,10 @@ def execute(source, root_value=None, context_value=None):
114129
115130 assert execute ("{ test }" ) == ({"test" : "[None, {}]" }, None )
116131
117- assert execute ("{ test }" , "Source!" ) == ({"test" : "['Source!', {}]" }, None ,)
132+ assert execute ("{ test }" , "Source!" ) == (
133+ {"test" : "['Source!', {}]" },
134+ None ,
135+ )
118136
119137 assert execute ('{ test(aStr: "String!") }' , "Source!" ) == (
120138 {"test" : "['Source!', {'aStr': 'String!'}]" },
@@ -144,7 +162,10 @@ def execute(source: str, root_value: Optional[Any] = None) -> ExecutionResult:
144162
145163 assert execute ("{ test }" ) == ({"test" : "[None, {}]" }, None )
146164
147- assert execute ("{ test }" , "Source!" ) == ({"test" : "['Source!', {}]" }, None ,)
165+ assert execute ("{ test }" , "Source!" ) == (
166+ {"test" : "['Source!', {}]" },
167+ None ,
168+ )
148169
149170 assert execute ('{ test(aStr: "String!") }' , "Source!" ) == (
150171 {"test" : "['Source!', {'a_str': 'String!'}]" },
@@ -177,7 +198,11 @@ def transforms_arguments_with_inputs_using_out_names():
177198 )
178199
179200 def execute (source , root_value = None ):
180- return graphql_sync (schema = schema , source = source , root_value = root_value ,)
201+ return graphql_sync (
202+ schema = schema ,
203+ source = source ,
204+ root_value = root_value ,
205+ )
181206
182207 assert execute ("{ test }" ) == ({"test" : "[None, {}]" }, None )
183208
0 commit comments