@@ -186,7 +186,7 @@ public void query() {
186
186
.additionalType (TestObject .class ).build ();
187
187
188
188
GraphQL graphQL = GraphQL .newGraphQL (schema ).build ();
189
- ExecutionResult result = graphQL .execute ("{ object { value(input:{key:\" test\" }) } }" , new Query ());
189
+ ExecutionResult result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ object { value(input:{key:\" test\" }) } }" , new Query () ));
190
190
assertTrue (result .getErrors ().isEmpty ());
191
191
assertEquals (((Map <String , Map <String , String >>) result .getData ()).get ("object" ).get ("value" ), "testa" );
192
192
}
@@ -196,7 +196,7 @@ public void queryMultipleDefinitions() {
196
196
GraphQLSchema schema = newAnnotationsSchema ().query (QueryMultipleDefinitions .class ).build ();
197
197
198
198
GraphQL graphQL = GraphQL .newGraphQL (schema ).build ();
199
- ExecutionResult result = graphQL .execute ("{ something(code: {firstField:\" a\" ,secondField:\" b\" }) somethingElse(code: {firstField:\" c\" ,secondField:\" d\" }) }" , new QueryMultipleDefinitions ());
199
+ ExecutionResult result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ something(code: {firstField:\" a\" ,secondField:\" b\" }) somethingElse(code: {firstField:\" c\" ,secondField:\" d\" }) }" , new QueryMultipleDefinitions () ));
200
200
assertTrue (result .getErrors ().isEmpty ());
201
201
assertEquals (((Map <String , String >) result .getData ()).get ("something" ), "ab" );
202
202
assertEquals (((Map <String , String >) result .getData ()).get ("somethingElse" ), "cd" );
@@ -207,11 +207,11 @@ public void queryWithRecursion() {
207
207
GraphQLSchema schema = newAnnotationsSchema ().query (QueryRecursion .class ).build ();
208
208
209
209
GraphQL graphQL = GraphQL .newGraphQL (schema ).build ();
210
- ExecutionResult result = graphQL .execute ("{ object { value(input:{key:\" test\" }) } }" , new QueryRecursion ());
210
+ ExecutionResult result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ object { value(input:{key:\" test\" }) } }" , new QueryRecursion () ));
211
211
assertTrue (result .getErrors ().isEmpty ());
212
212
assertEquals (((Map <String , Map <String , String >>) result .getData ()).get ("object" ).get ("value" ), "testa" );
213
213
214
- result = graphQL .execute ("{ object { value(input:{rec:{key:\" test\" }}) } }" , new QueryRecursion ());
214
+ result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ object { value(input:{rec:{key:\" test\" }}) } }" , new QueryRecursion () ));
215
215
assertTrue (result .getErrors ().isEmpty ());
216
216
assertEquals (((Map <String , Map <String , String >>) result .getData ()).get ("object" ).get ("value" ), "rectesta" );
217
217
}
@@ -221,7 +221,7 @@ public void queryWithList() {
221
221
GraphQLSchema schema = newAnnotationsSchema ().query (QueryList .class ).build ();
222
222
223
223
GraphQL graphQL = GraphQL .newGraphQL (schema ).build ();
224
- ExecutionResult result = graphQL .execute ("{ object { value(input:[[[{key:\" test\" , complex:[{subKey:\" subtest\" },{subKey:\" subtest2\" }]}]]]) } }" , new QueryList ());
224
+ ExecutionResult result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ object { value(input:[[[{key:\" test\" , complex:[{subKey:\" subtest\" },{subKey:\" subtest2\" }]}]]]) } }" , new QueryList () ));
225
225
assertEquals (((Map <String , Map <String , String >>) result .getData ()).get ("object" ).get ("value" ), "test-subtest" );
226
226
}
227
227
@@ -230,7 +230,7 @@ public void queryWithInterface() {
230
230
GraphQLSchema schema = newAnnotationsSchema ().query (QueryIface .class ).additionalType (TestObject .class ).build ();
231
231
232
232
GraphQL graphQL = GraphQL .newGraphQL (schema ).build ();
233
- ExecutionResult result = graphQL .execute ("{ iface { value(input:{key:\" test\" }) } }" , new QueryIface ());
233
+ ExecutionResult result = graphQL .execute (GraphQLHelper . createExecutionInput ( "{ iface { value(input:{key:\" test\" }) } }" , new QueryIface () ));
234
234
assertTrue (result .getErrors ().isEmpty ());
235
235
assertEquals (((Map <String , Map <String , String >>) result .getData ()).get ("iface" ).get ("value" ), "testa" );
236
236
}
0 commit comments