-
Notifications
You must be signed in to change notification settings - Fork 485
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
test(lambda): fix sync integration test #5948
Conversation
/runIntegrationTests |
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.
This should be marked as a refactor PR. The scope is much larger than test.
packages/core/src/test/awsService/appBuilder/explorer/walkthrough.test.ts
Outdated
Show resolved
Hide resolved
packages/core/src/test/awsService/appBuilder/wizards/deployTypeWizard.test.ts
Outdated
Show resolved
Hide resolved
packages/toolkit/.changes/next-release/Test-de189b97-989c-4c35-9a72-c874bb72cc92.json
Outdated
Show resolved
Hide resolved
Please do not overdo the decomposition. Or look for other, existing modules where parts of sync.ts might better fit. Do not add lots of granular single-purpose modules. |
The decomposition will be moving create prompter methods used in Sync, Deploy and Build command into its separate file. The partial effort on this is already in here : vicheey/aws-toolkit-vscode at refactor-sam-sync-deploy-build
Only shared components are extracted out. Despite so, everything will remain within |
8df7799
to
4bf1b1d
Compare
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 for improving prompterTester too!
/runintegrationtests |
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.
LGTM! Thanks for addressing the comments, it looks much better now.
Problem
The integration tests for sync is consistently failing. There seems to be some issue with mocking.
Since these tests are mocking the process run, we are moving these test to unit test to be executed for every CI
Solution
sync.tes.ts
sam.test.ts
in favor of added unit test insync.tes.ts
runInTerminal()
andProcessTerminal
class to a separate file(more decomposition for
sync.ts` will follow)DeployTypeWizard.test.ts
PrompterTester
class.License: I confirm that my contribution is made under the terms of the Apache 2.0 license.