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

Customer downloadable products GraphQL #802

Merged
merged 19 commits into from
Aug 29, 2019

Conversation

ldusan84
Copy link
Contributor

@ldusan84 ldusan84 commented Aug 5, 2019

Description (*)

Moved customer downloadable products into a new module and added tests.

Fixed Issues (if relevant)

  1. Extract logic related to customer from DownloadableGraphQl module into new one #685: Extract logic related to customer from DownloadableGraphQl module into new one

Manual testing scenarios (*)

  1. Get token as customer:
mutation {
  generateCustomerToken(
    email: "customer@example.com"
    password: "password"
  ) {
    token
  }
}
  1. Get customer's downloadable products:
{
    customerDownloadableProducts{
        items{
            order_increment_id
            date
            status
            download_url
            remaining_downloads
        }
    }
}

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)

@m2-community-project m2-community-project bot added this to Ready for Review in Pull Request Progress Aug 5, 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.

Please address my comments and remove duplicated tests \Magento\GraphQl\Downloadable\CustomerDownloadableProductsTest.

"description": "N/A",
"type": "magento2-module",
"require": {
"php": "~7.1.3||~7.2.0",
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
"php": "~7.1.3||~7.2.0",
"php": "~7.1.3||~7.2.0||~7.3.0",

status: String
download_url: String
remaining_downloads: String
}
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
}
}

* @magentoApiDataFixture Magento/Downloadable/_files/product_downloadable.php
* @magentoApiDataFixture Magento/Downloadable/_files/order_with_downloadable_product.php
*/
public function testGetCustomerDownloadableProducts()
Copy link
Contributor

Choose a reason for hiding this comment

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

This test can be simplified. Please have a look at \Magento\GraphQl\Downloadable\CustomerDownloadableProductsTest::testCustomerDownloadableProducts.

@m2-community-project m2-community-project bot moved this from Ready for Review to Changes Requested in Pull Request Progress Aug 5, 2019
@ldusan84
Copy link
Contributor Author

@lenaorobei I changed the things that you mentioned, please check.

@lenaorobei
Copy link
Contributor

@ldusan84 could you please pull latest mainline changes. We delivered recently #412 and it will impact your PR.

@ldusan84
Copy link
Contributor Author

@lenaorobei that's done.

…le into new one

- added composer dependency
- removed some hard dependencies because of DependencyTest bug MC-19635
…le into new one

- removed composer dependency because of DependencyTest bug MC-19635
@magento-engcom-team
Copy link
Contributor

Hi @lenaorobei, thank you for the review.
ENGCOM-5718 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

@lenaorobei
Copy link
Contributor

@magento run Functional Tests build

@ghost
Copy link

ghost commented Aug 29, 2019

Hi @ldusan84, 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
Development

Successfully merging this pull request may close these issues.

None yet

4 participants