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

test(Auth): Integration test related to apis for session, signOut #497

Merged
merged 3 commits into from May 27, 2020

Conversation

royjit
Copy link
Member

@royjit royjit commented May 27, 2020

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

@royjit royjit self-assigned this May 27, 2020
@royjit royjit added the auth Issues related to the Auth category label May 27, 2020
@royjit royjit requested a review from palpatim May 27, 2020 20:16
Copy link
Member

@palpatim palpatim left a comment

Choose a reason for hiding this comment

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

Approved w/comments

Comment on lines 16 to 18
let keychain = AWSUICKeyChainStore(service: "\(bundleID!).\(AWSCognitoIdentityUserPool.self)")
let namespace = "\(AWSMobileClient.default().userPoolClient!.userPoolConfiguration.clientId).\(username)"
let key = "\(namespace).tokenExpiration"
Copy link
Member

Choose a reason for hiding this comment

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

I don't like using production code to set up tests, but in this case, it seems like we should be using the exact same logic to make sure all session data is being removed. If we change the way session data is keyed and forget to update this method, we run the risk of hard-to-diagnose test failures.

@royjit royjit merged commit e63a33d into master May 27, 2020
@royjit royjit deleted the royjit/SessionIntegTest branch May 27, 2020 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auth Issues related to the Auth category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants