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

magento/graphql-ce#: deleteCustomerAddress. [Test coverage] Address "id" value should be specified. #1059

Merged
merged 2 commits into from
Nov 14, 2019

Conversation

atwixfirster
Copy link
Contributor

@atwixfirster atwixfirster commented Nov 13, 2019

Description (*)

PR provides a test coverage for the Address "id" value should be specified test case.

Source: Magento\CustomerGraphQl\Model\Resolver\DeleteCustomerAddress::resolve()

Fixed Issues (if relevant)

  1. magento/magento2#<issue_number>: Issue title

Manual testing scenarios (*)

  1. ...
  2. ...

Questions or comments

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 are green)

Thank you!

@atwixfirster atwixfirster changed the title magento/graphql-ce#975: [Test coverage] deleteCustomerAddress mutation. magento/graphql-ce#: deleteCustomerAddress. [Test coverage] Address "id" value should be specified. Nov 13, 2019
Copy link
Contributor

@lenaorobei lenaorobei left a comment

Choose a reason for hiding this comment

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

I don't think this is a valid test case. Schema looks like deleteCustomerAddress(id: Int!). For values like "" or null framework schema validation should take care of it and return Field \"deleteCustomerAddress\" argument \"id\" requires type Int!, found null which it actually does. For the value like 0 the message should be "Could not find address with ID \"0\"".

So the redundant check in resolver should be removed.

@magento-engcom-team
Copy link
Contributor

Hi @lenaorobei, thank you for the review.
ENGCOM-6278 has been created to process this Pull Request
✳️ @lenaorobei, could you please add one of the following labels to the Pull Request?

Label Description
Auto-Tests: Covered All changes in Pull Request is covered by auto-tests
Auto-Tests: Not Covered Changes in Pull Request requires coverage by auto-tests
Auto-Tests: Not Required Changes in Pull Request does not require coverage by auto-tests

@magento-engcom-team magento-engcom-team merged commit baec752 into 2.3-develop Nov 14, 2019
magento-engcom-team pushed a commit that referenced this pull request Nov 14, 2019
@ghost
Copy link

ghost commented Nov 14, 2019

Hi @atwixfirster, 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.

@okorshenko okorshenko deleted the test-coverage-deleteCustomerAddress branch December 18, 2019 22:21
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.

3 participants