Fix scenario tests failing with non-default region#9149
Merged
viren-nadkarni merged 18 commits intomasterfrom Feb 1, 2024
Merged
Fix scenario tests failing with non-default region#9149viren-nadkarni merged 18 commits intomasterfrom
viren-nadkarni merged 18 commits intomasterfrom
Conversation
8840d6c to
763508e
Compare
9363da1 to
4f09434
Compare
Other creds must be picked up from the execution role
S3 Image Test Results (AMD64 / ARM64) 2 files 2 suites 3m 16s ⏱️ Results for commit 1b03412. ♻️ This comment has been updated with latest results. |
LocalStack Community integration with Pro 2 files 2 suites 1h 22m 54s ⏱️ Results for commit e2c4a79. ♻️ This comment has been updated with latest results. |
680b153 to
1b03412
Compare
This reverts commit f83cf32.
721ac97 to
e2c4a79
Compare
steffyP
approved these changes
Feb 1, 2024
Member
steffyP
left a comment
There was a problem hiding this comment.
Thanks for jumping on this by improving and fixing the code 🚀 🙏
This file contains hidden or 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
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.
Summary
This PR fixes the following scenario tests that fail in non-default account/region:
tests.aws.scenario.bookstore.test_bookstore.TestBookstoreApplication.test_setuptests.aws.scenario.bookstore.test_bookstore.TestBookstoreApplication.test_lambda_dynamodbtests.aws.scenario.bookstore.test_bookstore.TestBookstoreApplication.test_search_booksChanges
Earlier, the credentials and region were hardcoded within the Lambda function code. Now, a proper IAM role is passed as a Lambda execution role. The function derives the proper credentials from this role and uses them for internal Boto instantiation.
Tests
See
ci/circleci: acceptance-testsjob for 1b03412 🟢 - this CI run used non-default test credentials, this demonstrates that the tests pass in such a situation.The affected tests have also been re-validated against AWS.