File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -327,7 +327,7 @@ class GraphQLTest extends Specification {
327327 result. errors. size() == 0
328328 }
329329
330- def " document with two operations but no specified operation throws " () {
330+ def " document with two operations but no specified operation does not throw " () {
331331 given :
332332
333333 GraphQLSchema schema = newSchema(). query(
@@ -343,10 +343,12 @@ class GraphQLTest extends Specification {
343343 """
344344
345345 when :
346- GraphQL . newGraphQL(schema). build(). execute(query)
346+ def er = GraphQL . newGraphQL(schema). build(). execute(query)
347347
348348 then :
349- thrown(GraphQLException )
349+ noExceptionThrown()
350+ ! er. errors. isEmpty()
351+ er. errors[0 ]. message. contains(" Must provide operation name if query contains multiple operations" )
350352 }
351353
352354 def " null mutation type does not throw an npe but returns and error" () {
You can’t perform that action at this time.
0 commit comments