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
Migrate PluginInstall
plugin logics into standalone command
#9942
Migrate PluginInstall
plugin logics into standalone command
#9942
Conversation
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.
@issea1015 Thank you, in general it looks very good!
I have few organization comments, also we need to configure some tests.
I think we need some unit test which doesn't depend on network: I imagine, that it may work as:
- Via fixture engine, setup some service fixture in which we will attempt to install plugin (some example:
await fixturesEngine.setup('function', { - Run our module in context of returned service path, with mocked (via
proxyquire
)child-process-ext/spawn
(so no real network communication occurs) - Confirm that:
npm
command was called withinstall
command- Plugin was added to
serverless.yml
We need also integration test, but that one actually is already there:
await fixturesEngine.setup('function', { |
83fc2d1
to
8179d00
Compare
Codecov Report
@@ Coverage Diff @@
## master #9942 +/- ##
==========================================
- Coverage 86.18% 85.59% -0.59%
==========================================
Files 329 332 +3
Lines 13065 13245 +180
==========================================
+ Hits 11260 11337 +77
- Misses 1805 1908 +103
Continue to review full report at Codecov.
|
@medikoo Thanks for the clear description of all your feedbacks! I think I covered all of them in recent commits. Hope you take a look again :) |
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.
@issea1015 that looks impressive! It's way way clearer now. I still have some remarks, but in general we're close to have it right.
Let me know what you think of my suggestions
6ec25a0
to
54f54f2
Compare
@medikoo Thanks for feedbacks with full background reasoning! It was seamless to follow them up. Let me know how it is now :) |
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.
@issea1015 that looks great! I have just few last notes, and we should be good to go
@medikoo Thanks for the step-by-step guidance all the while. That was impressive! |
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.
Thank you @issea1015 ! All good, still to completely keep support for internal plugin install
handling, some other changes also need to be reverted. I've commented under them specifically
@medikoo Gotcha 🤦 I might have rushed in fact 😛 |
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.
That looks great @issea1015 Thank you!
I assume you'd follow with plugin uninstall
with next PR?
@medikoo leave it to me! |
Addresses: #9740
This PR will seclude
plugin install
out of the internals. Let me make similar changes forplugin uninstall
once this PR is approved.All other requirements and feedbacks written by @medikoo in the issue are applied in this PR but didn't much simplify the logic for these reasons:
PluginInstall
class performs looks necessaryPlease feel free to give me a further guidance :)