Skip to content
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

fix: Update false-negative test case in Authentication.test #439

Merged
merged 1 commit into from
Aug 23, 2023

Conversation

adebayor123
Copy link
Member

Details

Addresses the concern from #436.

nit: This test will pass under certain conditions when it should fail (i.e., false negative).

Specifically, when this.credentials.expiration is undefined, and the expiration property of the value returned by AnonymousStorageCredentialsProvider is a Date object. When this happens, control flow will reach AnonymousCognitoCredentialsProvider, and the test needs a way to distinguish the value returned here from the expected value.

You can fix this by mocking the response of getCredentials, like was done in EnhancedAuthentication.test.ts here.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@qhanam qhanam merged commit 460770b into aws-observability:main Aug 23, 2023
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.

None yet

2 participants