Skip to content
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

issue-#25675 Added fix for #25675 issue to the 2.4 Magento version #26650

Merged

Conversation

siraybit
Copy link
Contributor

@siraybit siraybit commented Feb 2, 2020

Description
This pull request should fix issue #25675 in Magento 2.4

Fixed Issues
#25675: Unable add product to cart in Magento 2.3.3 backend when stock quantity is 1 - "The requested qty is not available"
Manual testing scenarios
Described here #25675

@m2-assistant
Copy link

m2-assistant bot commented Feb 2, 2020

Hi @molneek. 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.4-develop instance - deploy vanilla Magento instance

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

@siraybit
Copy link
Contributor Author

siraybit commented Feb 2, 2020

@dmytro-ch
I see that some tests are failed. E.g ReorderUsingVaultBraintreeTestVariation1_0, but I don't see the place where my code fix or my unit test influence on these test fails. Could you please advise, how to prevent failing the issues and finally add this of the issue to Magento?

@rogyar
Copy link
Contributor

rogyar commented Feb 2, 2020

Hi @molneek. The ReorderUsingVaultBraintreeTestVariation1_0 is a fluky test. It will be fixed soon after merging a corresponding fix into mainline. So, don't bother with this failing test, it's not related to your change somehow

@siraybit
Copy link
Contributor Author

siraybit commented Feb 3, 2020

Hi @rogyar. So in this case, does it mean that all these tests "Functional Tests B2B, Functional Tests CE, Functional Tests EE and Static Tests" are not related to my changes?
Do I need manually rerun check when these are fixed, or this happen automatically?

@rogyar
Copy link
Contributor

rogyar commented Feb 7, 2020

@magento run all tests

@siraybit
Copy link
Contributor Author

Hello @rogyar, seems like all tests passed

@rogyar rogyar self-assigned this Feb 16, 2020
@rogyar rogyar self-requested a review February 16, 2020 12:03
/**
* @var int
*/
private $itemQtyTestValue;
Copy link
Contributor

@rogyar rogyar Feb 16, 2020

Choose a reason for hiding this comment

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

Just a hint for the future. If we don't need to share value between different methods, there's no need to create an additional class property. You may use just local variables inside of the methods.

So $this->itemQtyTestValue will be simply $itemQtyTestValue inside of every method (test) of the current class

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@rogyar Thank you, I agree, I had some ideas about using it, but then changed my mind and just used this as this is already created

@magento-engcom-team
Copy link
Contributor

Hi @rogyar, thank you for the review.
ENGCOM-6910 has been created to process this Pull Request
✳️ @rogyar, 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

@engcom-Bravo
Copy link
Contributor

✔️ QA Passed

An order could be created and proceed without any errors if the product quantity is 1

@m2-assistant
Copy link

m2-assistant bot commented Feb 21, 2020

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

6 participants