Skip to content

S3ClientFactoryTest unit test fails to receive default us-west-2#3283

Merged
abvaidya merged 2 commits intoAthenZ:masterfrom
Bhuff1:feature/aws_region_default_unit_test
Apr 8, 2026
Merged

S3ClientFactoryTest unit test fails to receive default us-west-2#3283
abvaidya merged 2 commits intoAthenZ:masterfrom
Bhuff1:feature/aws_region_default_unit_test

Conversation

@Bhuff1
Copy link
Copy Markdown
Contributor

@Bhuff1 Bhuff1 commented Apr 7, 2026

Description

Unit test does not receive default us-west-2 region and fails due to EC2 IMDS. Addresses issue created here.

Contribution Checklist:

  • The pull request does not introduce any breaking changes
  • I have read the contribution guidelines.
  • Create an issue and link to the pull request.

… unit test expecting default region us-west-2

Signed-off-by: Benjamin Huff <benjaminehuff@gmail.com>
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the S3ClientFactoryTest to disable EC2 metadata during tests to prevent unnecessary IMDS calls. The review suggests updating the inline comment to more accurately reflect the purpose of the property and notes that setting system properties outside of a try block can lead to state leakage if initialization fails, recommending a safer setup pattern.

Signed-off-by: Benjamin Huff <benjaminehuff@gmail.com>
@Bhuff1 Bhuff1 force-pushed the feature/aws_region_default_unit_test branch from b370149 to 2af7090 Compare April 7, 2026 21:38
@abvaidya abvaidya merged commit 53949f9 into AthenZ:master Apr 8, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants