@@ -292,6 +292,20 @@ Feature: GraphQL introspection support
292
292
}
293
293
}
294
294
}
295
+ typeCreatePayloadData: __type(name: "createDummyGroupPayloadData") {
296
+ description,
297
+ fields {
298
+ name
299
+ type {
300
+ name
301
+ kind
302
+ ofType {
303
+ name
304
+ kind
305
+ }
306
+ }
307
+ }
308
+ }
295
309
}
296
310
"""
297
311
Then the response status code should be 200
@@ -304,10 +318,72 @@ Feature: GraphQL introspection support
304
318
And the JSON node "data.typeCreateInput.inputFields[0].name" should be equal to "bar"
305
319
And the JSON node "data.typeCreateInput.inputFields[1].name" should be equal to "baz"
306
320
And the JSON node "data.typeCreateInput.inputFields[2].name" should be equal to "clientMutationId"
307
- And the JSON node "data.typeCreatePayload.fields" should have 3 elements
308
- And the JSON node "data.typeCreatePayload.fields[0].name" should be equal to "id"
309
- And the JSON node "data.typeCreatePayload.fields[1].name" should be equal to "bar"
310
- And the JSON node "data.typeCreatePayload.fields[2].name" should be equal to "clientMutationId"
321
+ And the JSON node "data.typeCreatePayload.fields" should have 2 elements
322
+ And the JSON node "data.typeCreatePayload.fields[0].name" should be equal to "dummyGroup"
323
+ And the JSON node "data.typeCreatePayload.fields[0].type.name" should be equal to "createDummyGroupPayloadData"
324
+ And the JSON node "data.typeCreatePayload.fields[1].name" should be equal to "clientMutationId"
325
+ And the JSON node "data.typeCreatePayloadData.fields" should have 2 elements
326
+ And the JSON node "data.typeCreatePayloadData.fields[0].name" should be equal to "id"
327
+ And the JSON node "data.typeCreatePayloadData.fields[1].name" should be equal to "bar"
328
+
329
+ Scenario : Retrieve nested mutation payload data fields
330
+ When I send the following GraphQL request:
331
+ """
332
+ {
333
+ typeCreatePayload: __type(name: "createDummyPropertyPayload") {
334
+ description,
335
+ fields {
336
+ name
337
+ type {
338
+ name
339
+ kind
340
+ ofType {
341
+ name
342
+ kind
343
+ }
344
+ }
345
+ }
346
+ }
347
+ typeCreatePayloadData: __type(name: "createDummyPropertyPayloadData") {
348
+ description,
349
+ fields {
350
+ name
351
+ type {
352
+ name
353
+ kind
354
+ ofType {
355
+ name
356
+ kind
357
+ }
358
+ }
359
+ }
360
+ }
361
+ typeCreateNestedPayload: __type(name: "createDummyGroupNestedPayload") {
362
+ description,
363
+ fields {
364
+ name
365
+ type {
366
+ name
367
+ kind
368
+ ofType {
369
+ name
370
+ kind
371
+ }
372
+ }
373
+ }
374
+ }
375
+ }
376
+ """
377
+ Then the response status code should be 200
378
+ And the response should be in JSON
379
+ And the header "Content-Type" should be equal to "application/json"
380
+ And the JSON node "data.typeCreatePayload.fields" should have 2 elements
381
+ And the JSON node "data.typeCreatePayload.fields[0].name" should be equal to "dummyProperty"
382
+ And the JSON node "data.typeCreatePayload.fields[0].type.name" should be equal to "createDummyPropertyPayloadData"
383
+ And the JSON node "data.typeCreatePayload.fields[1].name" should be equal to "clientMutationId"
384
+ And the JSON node "data.typeCreatePayloadData.fields[3].name" should be equal to "group"
385
+ And the JSON node "data.typeCreatePayloadData.fields[3].type.name" should be equal to "createDummyGroupNestedPayload"
386
+ And the JSON node "data.typeCreateNestedPayload.fields[0].name" should be equal to "id"
311
387
312
388
Scenario : Retrieve an item through a GraphQL query
313
389
Given there are 4 dummy objects with relatedDummy
0 commit comments