-
Notifications
You must be signed in to change notification settings - Fork 34
Add --format=json option to status command #86
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
Add --format=json option to status command #86
Conversation
Functional Acceptance Test Results❌ One or more functional acceptance tests have failed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
Output for failed tests is below. If many tests have failed only the first 5 will be included. If you need additional information please reach out to the Magento Cloud team for more details. This comment was generated by Jenkins job magento-cloud-patches/functional build 102. |
PHP 7.2 Acceptance72CeCest OutputThis comment was generated by Jenkins job magento-cloud-patches/functional build 102. |
|
maybe @viktym can review? |
|
@peterjaap Please merge |
|
Hi @peterjaap |
|
@bubasuma I merged develop into my branch, should be uptodate now! |
Functional Acceptance Test Results❌ One or more functional acceptance tests have failed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
Output for failed tests is below. If many tests have failed only the first 5 will be included. If you need additional information please reach out to the Magento Cloud team for more details. This comment was generated by Jenkins job magento-cloud-patches/functional build 118. |
PHP 7.3 Acceptance73CeCest OutputThis comment was generated by Jenkins job magento-cloud-patches/functional build 118. |
|
Hi @peterjaap |
|
Proposed changes to Magento\CloudPatches\Command\Process\ShowStatus |
Co-authored-by: Viktor Tymchynskyi <vtymchynskyi@magento.com>
Sorry I'm not big on tests. What exactly do you want me to add there? |
Ok, we can skip unit test for this code |
Functional Acceptance Test Results✅ All functional acceptance tests have passed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
This comment was generated by Jenkins job magento-cloud-patches/functional build 119. |
|
@viktym I've committed the changes that refactored the |
Functional Acceptance Test Results❌ One or more functional acceptance tests have failed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
Output for failed tests is below. If many tests have failed only the first 5 will be included. If you need additional information please reach out to the Magento Cloud team for more details. This comment was generated by Jenkins job magento-cloud-patches/functional build 120. |
PHP 7.2 Acceptance72CeCest OutputThis comment was generated by Jenkins job magento-cloud-patches/functional build 120. |
src/Command/Status.php
Outdated
| if ($input->getOption('format') !== 'json') { | ||
| $output->writeln('<info>' . $this->magentoVersion->get() . '</info>'); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if ($input->getOption('format') !== 'json') { | |
| $output->writeln('<info>' . $this->magentoVersion->get() . '</info>'); | |
| } | |
| if ($input->getOption('format') !== 'json') { | |
| $output->writeln('<info>' . $this->magentoVersion->get() . '</info>'); | |
| } |
@peterjaap Better to move this code to \Magento\CloudPatches\Command\Process\ShowStatus class along with \Magento\CloudPatches\Composer\MagentoVersion dependency. In this case you also need to update constructors in \Magento\CloudPatches\Test\Unit\Command\Process\ShowStatusTest and \Magento\CloudPatches\Test\Unit\Command\StatusTest
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, please update unit tests \Magento\CloudPatches\Test\Unit\Command\Process\ShowStatusTest and \Magento\CloudPatches\Test\Unit\Command\StatusTest because currently they are failing after moving \Magento\CloudPatches\Composer\MagentoVersion dependency
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No thanks. You can do it if you'd like, you were the one that suggested the change.
I'll just close this PR otherwise, it has taken me too much time already for such a little feature.
And people wonder why it takes ages to merge something into the Magento codebase...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@peterjaap no problem, I can help you with the unit tests update. It's not about Magento, you will not be able to merge a PR to any other OS project with red builds. The requirement for test coverage is in DoD (definition of done), sorry.
Please check PR peterjaap#1
… of Status command
Functional Acceptance Test Results✅ All functional acceptance tests have passed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
This comment was generated by Jenkins job magento-cloud-patches/functional build 121. |
Co-authored-by: Viktor Tymchynskyi <vtymchynskyi@magento.com>
Functional Acceptance Test Results✅ All functional acceptance tests have passed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
This comment was generated by Jenkins job magento-cloud-patches/functional build 122. |
- Update unit tests after moving MagentoVersion dependency
|
@viktym thanks!! I merged your PR into my branch. |
Functional Acceptance Test Results✅ All functional acceptance tests have passed. PHP 7.2
PHP 7.3
PHP 7.4
PHP 8.1
This comment was generated by Jenkins job magento-cloud-patches/functional build 123. |
|
@peterjaap thanks for your contribution. This PR will be processed and the code changes will be available in the next |
|
@viktym the Pull Request is successfully imported. |
|
It will be in the next release MCP 1.0.20 |
MCLOUD-11149: MCP Release 1.0.24
Description
This PR adds a
--format=jsonto thevendor/bin/magento-patches statuscommand.This allows us to automate stuff concerning these patches better in our CI/CD deployments.
Contribution checklist