This repository was archived by the owner on Dec 19, 2019. It is now read-only.
File tree 1 file changed +26
-8
lines changed
dev/tests/api-functional/testsuite/Magento/GraphQl/Bundle 1 file changed +26
-8
lines changed Original file line number Diff line number Diff line change @@ -87,7 +87,7 @@ public function testAddBundleProductToCart()
87
87
{
88
88
data:{
89
89
sku:" {$ sku }"
90
- qty :1
90
+ quantity :1
91
91
}
92
92
bundle_options:[
93
93
{
@@ -102,10 +102,9 @@ public function testAddBundleProductToCart()
102
102
]
103
103
}) {
104
104
cart {
105
- cart_id
106
105
items {
107
106
id
108
- qty
107
+ quantity
109
108
product {
110
109
sku
111
110
}
@@ -128,12 +127,11 @@ public function testAddBundleProductToCart()
128
127
}
129
128
QUERY ;
130
129
131
- $ response = $ this ->graphQlQuery ($ query );
130
+ $ response = $ this ->graphQlMutation ($ query );
132
131
133
132
$ this ->assertArrayHasKey ('addBundleProductsToCart ' , $ response );
134
133
$ this ->assertArrayHasKey ('cart ' , $ response ['addBundleProductsToCart ' ]);
135
134
$ cart = $ response ['addBundleProductsToCart ' ]['cart ' ];
136
- $ this ->assertEquals ($ maskedQuoteId , $ cart ['cart_id ' ]);
137
135
$ bundleItem = current ($ cart ['items ' ]);
138
136
$ this ->assertEquals ($ sku , $ bundleItem ['product ' ]['sku ' ]);
139
137
$ bundleItemOption = current ($ bundleItem ['bundle_options ' ]);
@@ -170,7 +168,7 @@ public function testAddBundleToCartWithoutOptions()
170
168
{
171
169
data:{
172
170
sku:"bundle-product"
173
- qty :1
171
+ quantity :1
174
172
}
175
173
bundle_options:[
176
174
{
@@ -185,12 +183,32 @@ public function testAddBundleToCartWithoutOptions()
185
183
]
186
184
}) {
187
185
cart {
188
- cart_id
186
+ items {
187
+ id
188
+ quantity
189
+ product {
190
+ sku
191
+ }
192
+ ... on BundleCartItem {
193
+ bundle_options {
194
+ id
195
+ label
196
+ type
197
+ values {
198
+ id
199
+ label
200
+ price
201
+ quantity
202
+ }
203
+ }
204
+ }
205
+ }
189
206
}
190
207
}
191
208
}
192
209
QUERY ;
193
210
194
- $ this ->graphQlQuery ($ query );
211
+ $ response = $ this ->graphQlMutation ($ query );
212
+ $ what = 'is happening ' ;
195
213
}
196
214
}
You can’t perform that action at this time.
0 commit comments