@@ -21,7 +21,7 @@ Feature: GraphQL introspection support
2121 When I send the following GraphQL request:
2222 """
2323 {
24- type1: __type(name: "DummyProductItem ") {
24+ type1: __type(name: "DummyProduct ") {
2525 description,
2626 fields {
2727 name
@@ -35,7 +35,7 @@ Feature: GraphQL introspection support
3535 }
3636 }
3737 }
38- type2: __type(name: "DummyAggregateOfferItemConnection ") {
38+ type2: __type(name: "DummyAggregateOfferConnection ") {
3939 description,
4040 fields {
4141 name
@@ -49,7 +49,7 @@ Feature: GraphQL introspection support
4949 }
5050 }
5151 }
52- type3: __type(name: "DummyAggregateOfferItemEdge ") {
52+ type3: __type(name: "DummyAggregateOfferEdge ") {
5353 description,
5454 fields {
5555 name
@@ -69,12 +69,53 @@ Feature: GraphQL introspection support
6969 And the response should be in JSON
7070 And the header "Content-Type" should be equal to "application/json"
7171 And the JSON node "data.type1.description" should be equal to "Dummy Product."
72- And the JSON node "data.type1.fields[1].type.name" should be equal to "DummyAggregateOfferItemConnection "
72+ And the JSON node "data.type1.fields[1].type.name" should be equal to "DummyAggregateOfferConnection "
7373 And the JSON node "data.type2.fields[0].name" should be equal to "edges"
74- And the JSON node "data.type2.fields[0].type.ofType.name" should be equal to "DummyAggregateOfferItemEdge "
74+ And the JSON node "data.type2.fields[0].type.ofType.name" should be equal to "DummyAggregateOfferEdge "
7575 And the JSON node "data.type3.fields[0].name" should be equal to "node"
7676 And the JSON node "data.type3.fields[1].name" should be equal to "cursor"
77- And the JSON node "data.type3.fields[0].type.name" should be equal to "DummyAggregateOfferItem"
77+ And the JSON node "data.type3.fields[0].type.name" should be equal to "DummyAggregateOffer"
78+
79+ Scenario : Introspect types with different serialization groups for item_query and collection_query
80+ When I send the following GraphQL request:
81+ """
82+ {
83+ type1: __type(name: "DummyDifferentGraphQlSerializationGroupCollection") {
84+ description,
85+ fields {
86+ name
87+ type {
88+ name
89+ kind
90+ ofType {
91+ name
92+ kind
93+ }
94+ }
95+ }
96+ }
97+ type2: __type(name: "DummyDifferentGraphQlSerializationGroupItem") {
98+ description,
99+ fields {
100+ name
101+ type {
102+ name
103+ kind
104+ ofType {
105+ name
106+ kind
107+ }
108+ }
109+ }
110+ }
111+ }
112+ """
113+ Then the response status code should be 200
114+ And the response should be in JSON
115+ And the header "Content-Type" should be equal to "application/json"
116+ And the JSON node "data.type1.description" should be equal to "Dummy with different serialization groups for item_query and collection_query."
117+ And the JSON node "data.type1.fields[3].name" should not exist
118+ And the JSON node "data.type2.fields[3].name" should be equal to "title"
78119
79120 Scenario : Introspect deprecated queries
80121 When I send the following GraphQL request:
@@ -121,7 +162,7 @@ Feature: GraphQL introspection support
121162 When I send the following GraphQL request:
122163 """
123164 {
124- __type(name: "DeprecatedResourceItem ") {
165+ __type(name: "DeprecatedResource ") {
125166 fields(includeDeprecated: true) {
126167 name
127168 isDeprecated
@@ -224,7 +265,7 @@ Feature: GraphQL introspection support
224265 When I send the following GraphQL request:
225266 """
226267 {
227- __type(name: "DummyItem ") {
268+ __type(name: "Dummy ") {
228269 description,
229270 fields {
230271 name
@@ -250,7 +291,7 @@ Feature: GraphQL introspection support
250291 When I send the following GraphQL request:
251292 """
252293 {
253- typeQuery: __type(name: "DummyGroupItem ") {
294+ typeQuery: __type(name: "DummyGroup ") {
254295 description,
255296 fields {
256297 name
@@ -390,7 +431,7 @@ Feature: GraphQL introspection support
390431 When I send the following GraphQL request:
391432 """
392433 {
393- dummyItem : dummy(id: "/dummies/3") {
434+ dummy : dummy(id: "/dummies/3") {
394435 name
395436 relatedDummy {
396437 id
@@ -403,6 +444,6 @@ Feature: GraphQL introspection support
403444 Then the response status code should be 200
404445 And the response should be in JSON
405446 And the header "Content-Type" should be equal to "application/json"
406- And the JSON node "data.dummyItem .name" should be equal to "Dummy #3"
407- And the JSON node "data.dummyItem .relatedDummy.name" should be equal to "RelatedDummy #3"
408- And the JSON node "data.dummyItem .relatedDummy.__typename" should be equal to "RelatedDummyItem "
447+ And the JSON node "data.dummy .name" should be equal to "Dummy #3"
448+ And the JSON node "data.dummy .relatedDummy.name" should be equal to "RelatedDummy #3"
449+ And the JSON node "data.dummy .relatedDummy.__typename" should be equal to "RelatedDummy "
0 commit comments