@@ -1164,7 +1164,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
11641164 func test_setMasterPassword( ) async throws {
11651165 let account = Account . fixture ( )
11661166 client. result = . httpSuccess( testData: . emptyResponse)
1167- clientService. mockCrypto. updatePasswordResult = . success(
1167+ clientService. mockCrypto. makeUpdatePasswordResult = . success(
11681168 UpdatePasswordResponse ( passwordHash: " NEW_PASSWORD_HASH " , newKey: " NEW_KEY " )
11691169 )
11701170 stateService. accountEncryptionKeys [ " 1 " ] = AccountEncryptionKeys (
@@ -1222,7 +1222,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
12221222
12231223 /// `setMasterPassword()` throws an error if one occurs.
12241224 func test_setMasterPassword_error( ) async {
1225- clientService. mockCrypto. updatePasswordResult = . failure( BitwardenTestError . example)
1225+ clientService. mockCrypto. makeUpdatePasswordResult = . failure( BitwardenTestError . example)
12261226 stateService. activeAccount = Account . fixtureWithTdeNoPassword ( )
12271227 stateService. accountEncryptionKeys [ " 1 " ] = AccountEncryptionKeys (
12281228 accountKeys: . fixture( ) ,
@@ -1249,7 +1249,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
12491249 . httpSuccess( testData: . organizationKeys) ,
12501250 . httpSuccess( testData: . emptyResponse) ,
12511251 ]
1252- clientService. mockCrypto. updatePasswordResult = . success(
1252+ clientService. mockCrypto. makeUpdatePasswordResult = . success(
12531253 UpdatePasswordResponse ( passwordHash: " NEW_PASSWORD_HASH " , newKey: " NEW_KEY " )
12541254 )
12551255 stateService. accountEncryptionKeys [ " 1 " ] = AccountEncryptionKeys (
@@ -1267,7 +1267,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
12671267 resetPasswordAutoEnroll: true
12681268 )
12691269
1270- XCTAssertEqual ( clientService. mockCrypto. updatePasswordNewPassword , " NEW_PASSWORD " )
1270+ XCTAssertEqual ( clientService. mockCrypto. makeUpdatePasswordNewPassword , " NEW_PASSWORD " )
12711271 XCTAssertEqual (
12721272 stateService. accountEncryptionKeys [ " 1 " ] ,
12731273 AccountEncryptionKeys (
@@ -2340,7 +2340,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
23402340
23412341 /// `updateMasterPassword()` rethrows an error if an error occurs.
23422342 func test_updateMasterPassword_error( ) async throws {
2343- clientService. mockCrypto. updatePasswordResult = . failure( BitwardenTestError . example)
2343+ clientService. mockCrypto. makeUpdatePasswordResult = . failure( BitwardenTestError . example)
23442344 stateService. activeAccount = . fixture( )
23452345
23462346 await assertAsyncThrows ( error: BitwardenTestError . example) {
@@ -2356,7 +2356,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
23562356 /// `updateMasterPassword()` performs the API request to update the user's password.
23572357 func test_updateMasterPassword_weakMasterPasswordOnLogin( ) async throws {
23582358 client. result = . httpSuccess( testData: . emptyResponse)
2359- clientService. mockCrypto. updatePasswordResult = . success(
2359+ clientService. mockCrypto. makeUpdatePasswordResult = . success(
23602360 UpdatePasswordResponse ( passwordHash: " NEW_PASSWORD_HASH " , newKey: " NEW_KEY " )
23612361 )
23622362 stateService. accountEncryptionKeys [ " 1 " ] = AccountEncryptionKeys (
@@ -2375,7 +2375,7 @@ class AuthRepositoryTests: BitwardenTestCase { // swiftlint:disable:this type_bo
23752375 reason: . weakMasterPasswordOnLogin
23762376 )
23772377
2378- XCTAssertEqual ( clientService. mockCrypto. updatePasswordNewPassword , " NEW_PASSWORD " )
2378+ XCTAssertEqual ( clientService. mockCrypto. makeUpdatePasswordNewPassword , " NEW_PASSWORD " )
23792379
23802380 XCTAssertEqual ( client. requests. count, 1 )
23812381 XCTAssertNotNil ( client. requests [ 0 ] . body)
0 commit comments