Follow SDK method renaming: fix_recovery_issues() got renamed to recover()

This commit is contained in:
Benoit Marty 2023-12-05 17:40:47 +01:00
parent 8f5fed48ab
commit e8e2e95e02
5 changed files with 11 additions and 11 deletions

View file

@ -89,7 +89,7 @@ class SecureBackupEnterRecoveryKeyPresenter @Inject constructor(
action: MutableState<Async<Unit>>
) = launch {
suspend {
encryptionService.fixRecoveryIssues(recoveryKey).getOrThrow()
encryptionService.recover(recoveryKey).getOrThrow()
}.runCatchingUpdatingState(action)
}
}

View file

@ -73,7 +73,7 @@ class SecureBackupEnterRecoveryKeyPresenterTest {
inProgress = false,
)
)
encryptionService.givenFixRecoveryIssuesFailure(AN_EXCEPTION)
encryptionService.givenRecoverFailure(AN_EXCEPTION)
withRecoveryKeyState.eventSink(SecureBackupEnterRecoveryKeyEvents.Submit)
val loadingState = awaitItem()
assertThat(loadingState.submitAction).isEqualTo(Async.Loading<Unit>())
@ -85,7 +85,7 @@ class SecureBackupEnterRecoveryKeyPresenterTest {
val clearedState = awaitItem()
assertThat(clearedState.submitAction).isEqualTo(Async.Uninitialized)
assertThat(clearedState.isSubmitEnabled).isTrue()
encryptionService.givenFixRecoveryIssuesFailure(null)
encryptionService.givenRecoverFailure(null)
clearedState.eventSink(SecureBackupEnterRecoveryKeyEvents.Submit)
val loadingState2 = awaitItem()
assertThat(loadingState2.submitAction).isEqualTo(Async.Loading<Unit>())