Skip to content
This repository has been archived by the owner on Dec 19, 2019. It is now read-only.

issue #485 [Test coverage] testReSetShippingMethod #496

Merged
merged 14 commits into from
Mar 30, 2019

Conversation

vovsky
Copy link
Contributor

@vovsky vovsky commented Mar 16, 2019

Description (*)

Added API functional test to cover reset shipping method case.

Fixed Issues (if relevant)

  1. [Test coverage] testReSetShippingMethod #485: [Test coverage] testReSetShippingMethod

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

self::assertArrayHasKey('setShippingMethodsOnCart', $response);
self::assertArrayHasKey('cart', $response['setShippingMethodsOnCart']);
self::assertArrayHasKey('shipping_addresses', $response['setShippingMethodsOnCart']['cart']);
foreach ($response['setShippingMethodsOnCart']['cart']['shipping_addresses'] as $address) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we use foreach that means we have a few shipping addresses for Cart.
Need to check why don't we have an exception Multishipping is not supported with this preconditions
Thanks

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mean to change shipping_addresses field of Cart type to shipping_address
and to throw Multishipping is not supported exception in \Magento\QuoteGraphQl\Model\Resolver\ShippingAddresses resolver if there is more than one shipping address?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mean to change shipping_addresses field of Cart type to shipping_address
and to throw Multishipping is not supported exception in \Magento\QuoteGraphQl\Model\Resolver\ShippingAddresses resolver if there is more than one shipping address?

yogeshsuhagiya and others added 8 commits March 26, 2019 12:16
…ogesh-5' into 2.3-develop-graphql-PR-yogesh-5
…hippingMethod

# Conflicts:
#	dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Customer/SetShippingMethodsOnCartTest.php
#	dev/tests/api-functional/testsuite/Magento/GraphQl/Quote/Guest/SetShippingMethodsOnCartTest.php
@ghost
Copy link

ghost commented Mar 30, 2019

Hi @vovsky, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants