Skip to content

Commit 96738f5

Browse files
authored
chore: fixing integration test failure (#4032)
1 parent 1707654 commit 96738f5

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

AmplifyPlugins/Auth/Tests/AuthHostApp/AuthIntegrationTests/CredentialStore/CredentialStoreConfigurationTests.swift

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ class CredentialStoreConfigurationTests: AWSAuthBaseTest {
122122
/// - When:
123123
/// - We invoke a new Credential store with new Auth Configuration where identity user pool gets added
124124
/// - Then:
125-
/// - The keychain should be cleared
125+
/// - The keychain should be NOT be cleared
126126
///
127127
func testCredentialsMigratedOnNotSupportedConfigurationChange() {
128128
// Given
@@ -147,7 +147,7 @@ class CredentialStoreConfigurationTests: AWSAuthBaseTest {
147147

148148
// Then
149149
let credentials = try? newCredentialStore.retrieveCredential()
150-
XCTAssertNil(credentials)
150+
XCTAssertNotNil(credentials)
151151
}
152152

153153
/// Test clearing of existing credentials when a configuration changes for identity pool
@@ -175,8 +175,10 @@ class CredentialStoreConfigurationTests: AWSAuthBaseTest {
175175
}
176176

177177
// When configuration changed
178-
let newAuthConfig = AuthConfiguration.identityPools(IdentityPoolConfigurationData(poolId: "changed",
179-
region: "changed"))
178+
let newAuthConfig = AuthConfiguration.identityPools(
179+
IdentityPoolConfigurationData(
180+
poolId: "changed",
181+
region: "changed"))
180182
let newCredentialStore = AWSCognitoAuthCredentialStore(authConfiguration: newAuthConfig)
181183

182184
// Then

0 commit comments

Comments
 (0)