Skip to content

Commit

Permalink
Fixes a test when there is no default region on the machine, as is th…
Browse files Browse the repository at this point in the history
…e case in a GitHub Action.

Signed-off-by: David Venable <[email protected]>
  • Loading branch information
dlvenable committed May 25, 2023
1 parent f42ffbc commit 4656683
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@ void providerFromOptions_with_invalid_StsRoleArn_throws(final String stsRoleArn)
void providerFromOptions_with_StsRoleArn() {
when(awsCredentialsOptions.getStsRoleArn())
.thenReturn(createStsRole());
when(awsCredentialsOptions.getRegion())
.thenReturn(Region.US_EAST_1);
final AwsCredentialsProvider awsCredentialsProvider = createObjectUnderTest().providerFromOptions(awsCredentialsOptions);
assertThat(awsCredentialsProvider, instanceOf(StsAssumeRoleCredentialsProvider.class));
}
Expand Down

0 comments on commit 4656683

Please sign in to comment.