Skip to content

Forward port fix to keep bundle options in bundle after duplicating it #24703

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

hostep
Copy link
Contributor

@hostep hostep commented Sep 23, 2019

Description (*)

This is a forward port of https://github.com/magento-engcom/magento2ce/pull/1217 which got included in Magento 2.2.4 but somehow didn't make it in the 2.3-develop branch.
Since the PR mentioned above isn't publicly viewable, I have no idea what is mentioned inside it.

But this fixes the fact that when duplicated a bundle product in the backend of Magento, it will still keeps the bundled options associated to the original product.

Fixed Issues (if relevant)

  1. 2.2.2 - Duplicating Bundle Product Removes Bundle Options From Original Product #13126: 2.2.2 - Duplicating Bundle Product Removes Bundle Options From Original Product
  2. Duplicate bundle product's child products issue. #14112: Duplicate bundle product's child products issue.

Manual testing scenarios (*)

  1. Create a simple product
  2. Create a bundle product, adding the aforementioned simple product as a bundle option
  3. Save the bundle product
  4. Click Save and Duplicate the bundle product
  5. Check if the original product still has its bundle options

Questions or comments

None

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)

…ons From Original Product

(cherry picked from commit b57eb03)
…ons From Original Product

(cherry picked from commit d8bd657)
@hostep hostep requested a review from akaplya as a code owner September 23, 2019 18:09
@m2-assistant
Copy link

m2-assistant bot commented Sep 23, 2019

Hi @hostep. Thank you for your contribution
Here is some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento give me test instance - deploy test instance based on PR changes
  • @magento give me 2.3-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Guide documentation.

@hostep
Copy link
Contributor Author

hostep commented Sep 23, 2019

If somebody could give me a hint why the integration tests are failing that would be appreciated!
Screenshot 2019-09-23 at 21 52 35

When manually testing, I do see those success messages:
Screenshot 2019-09-23 at 21 58 09

@kalpmehta kalpmehta self-assigned this Sep 24, 2019
@kalpmehta kalpmehta added the Auto-Tests: Covered All changes in Pull Request is covered by auto-tests label Sep 24, 2019
@ihor-sviziev
Copy link
Contributor

Hi @hostep,
Just try to debug, these messages might appear just in opposite direction than you see in the admin

@hostep
Copy link
Contributor Author

hostep commented Sep 25, 2019

Hmm, I think it might be something different, otherwise the "actual results" would also show up.

I'll try to somehow setup the integration tests on my local a bit later this week and try to figure it out from there.

Thanks for the feedback!

@hostep hostep force-pushed the forward-port-ce-pr-1217 branch from 0f2ff6d to 629fcdf Compare September 25, 2019 18:29
@hostep
Copy link
Contributor Author

hostep commented Sep 25, 2019

Ok figured it out, was able to reproduce on my local and fix it as well.
It looks like all requests in integration tests in Magento 2.3.0 and higher need to explicitly mention which HTTP method they should use.
Found inspiration by a similar change in a different integration test.

@kalpmehta
Copy link
Contributor

Thanks @ihor-sviziev and @hostep

@kalpmehta
Copy link
Contributor

@magento give me test instance

@magento-engcom-team
Copy link
Contributor

Hi @kalpmehta. Thank you for your request. I'm working on Magento instance for you

@magento-engcom-team
Copy link
Contributor

Hi @kalpmehta, here is your new Magento instance.
Admin access: https://pr-24703.instances.magento-community.engineering/admin
Login: admin Password: 123123q

@magento-engcom-team
Copy link
Contributor

Hi @kalpmehta, thank you for the review.
ENGCOM-5953 has been created to process this Pull Request

@engcom-Delta
Copy link
Contributor

✔️ QA passed

@m2-assistant
Copy link

m2-assistant bot commented Sep 27, 2019

Hi @hostep, 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 join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants