forked from magento/magento2
-
Notifications
You must be signed in to change notification settings - Fork 0
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
[Backport] Adding support for variadic arguments' method in generated proxy c… #31
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…agento#15933 - Merge Pull Request magento#15933 from rogyar/magento2:2.1-empty-anchors-fix - Merged commits: 1. 4caef44
Accepted Public Pull Requests: - magento#15933: Do not display anchor if admin submenu has no children (by @rogyar)
…inition does not requir… magento#15949 - Merge Pull Request magento#15949 from saurabh-aureate/magento2:2.1-develop-PR-port-15891 - Merged commits: 1. 063840f
…chCriteria - added zero … magento#15945 - Merge Pull Request magento#15945 from vgelani/magento2:2.1-develop-PR-port-15322 - Merged commits: 1. f3108a3
…rnal\Magento\Framework\D… magento#15943 - Merge Pull Request magento#15943 from vgelani/magento2:2.1-develop-PR-port-15892 - Merged commits: 1. 63ebb61 2. 3c58390
…rnal\Magento\Framework\D… magento#15943
…chCriteria - added zero … magento#15945
…inition does not requir… magento#15949
Accepted Public Pull Requests: - magento#15943: [Backport] Wrong annotation in _toOptionArray : lib\internal\Magento\Framework\D� (by @vgelani) - magento#15945: [Backport] ISSUE-11477 - fixed Swagger response for searchCriteria - added zero � (by @vgelani) - magento#15949: [Backport]No need to pass method parameter as method definition does not requir� (by @saurabh-aureate) Fixed GitHub Issues: - magento#11477: Magento REST API Schema (Swagger) is not compatible with Search Criteria (reported by @careys7) has been fixed in magento#15945 by @vgelani in 2.1-develop branch Related commits: 1. f3108a3
gelanivishal
pushed a commit
that referenced
this pull request
Oct 17, 2018
- Merge Pull Request magento/bulk-api-ce#31 from magento/bulk-api-ce:async-delete - Merged commits: 1. 069aa1c 2. 694d219
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Original Pull Request
magento#15177
Proxy for class with variadic argument method
Pull request fixes proxy class generation, so class with method with variadic arguments can be also used in proxy class.
Description
In
Magento/Framework/ObjectManager/Code/Generator/Proxy
(lines 158, 159) I added check if parameter is variadic and if so its name is suffixed by '...', so then in method_getMethodBody()
proxy method body is generated properly.Fixed Issues (if relevant)
Extends fixes from magento@27065cf
Manual testing scenarios
/generated/code
.I was trying to extend unit test for modified class (
Magento\Framework\ObjectManager\Test\Unit\Code\Generator
), so it also would generate and test class with method with variadic argument, but with no success. Test broke on (mocked) method -generateResultFileName()
. Actually, I only tried to edit fixtures files for test, not test itself:Magento\Framework\ObjectManager\Code\Generator\Sample
, adding method like:And
Magento\Framework\ObjectManager\Code\Generator\Sample_Proxy.txt
, adding generated method like this:Maybe someone else would be able to extend unit test for this class. If we don't change anything in case of unit tests, test is green.