mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 16:10:00 +00:00
Merge pull request #7287 from element-hq/renovate/org.matrix.rustcomponents-sdk-android-26.x
Update dependency org.matrix.rustcomponents:sdk-android to v26.07.28
This commit is contained in:
+2
@@ -141,6 +141,8 @@ class QrCodeLoginFlowNode(
|
|||||||
}
|
}
|
||||||
QrLoginException.CheckCodeAlreadySent,
|
QrLoginException.CheckCodeAlreadySent,
|
||||||
QrLoginException.CheckCodeCannotBeSent,
|
QrLoginException.CheckCodeCannotBeSent,
|
||||||
|
QrLoginException.ContinuationAlreadySent,
|
||||||
|
QrLoginException.ContinuationCannotBeSent,
|
||||||
QrLoginException.UnsupportedQrCodeType,
|
QrLoginException.UnsupportedQrCodeType,
|
||||||
QrLoginException.Unknown -> {
|
QrLoginException.Unknown -> {
|
||||||
Timber.e(error, "Unknown error found")
|
Timber.e(error, "Unknown error found")
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ test_detekt_test = { module = "io.gitlab.arturbosch.detekt:detekt-test", version
|
|||||||
# https://github.com/matrix-org/matrix-rust-components-kotlin/commits/main/sdk/sdk-android/src/main/kotlin/org/matrix/rustcomponents/sdk/matrix_sdk_ffi.kt
|
# https://github.com/matrix-org/matrix-rust-components-kotlin/commits/main/sdk/sdk-android/src/main/kotlin/org/matrix/rustcomponents/sdk/matrix_sdk_ffi.kt
|
||||||
# All new features should not be implemented in the pull request that upgrades the version, developers should
|
# All new features should not be implemented in the pull request that upgrades the version, developers should
|
||||||
# only fix API breaks and may add some TODOs.
|
# only fix API breaks and may add some TODOs.
|
||||||
matrix_sdk = "org.matrix.rustcomponents:sdk-android:26.07.23"
|
matrix_sdk = "org.matrix.rustcomponents:sdk-android:26.07.28"
|
||||||
|
|
||||||
# Others
|
# Others
|
||||||
coil = { module = "io.coil-kt.coil3:coil", version.ref = "coil" }
|
coil = { module = "io.coil-kt.coil3:coil", version.ref = "coil" }
|
||||||
|
|||||||
+2
@@ -20,6 +20,8 @@ sealed class QrLoginException : Exception() {
|
|||||||
data object OtherDeviceNotSignedIn : QrLoginException()
|
data object OtherDeviceNotSignedIn : QrLoginException()
|
||||||
data object CheckCodeAlreadySent : QrLoginException()
|
data object CheckCodeAlreadySent : QrLoginException()
|
||||||
data object CheckCodeCannotBeSent : QrLoginException()
|
data object CheckCodeCannotBeSent : QrLoginException()
|
||||||
|
data object ContinuationAlreadySent : QrLoginException()
|
||||||
|
data object ContinuationCannotBeSent : QrLoginException()
|
||||||
data object UnsupportedQrCodeType : QrLoginException()
|
data object UnsupportedQrCodeType : QrLoginException()
|
||||||
data object Unknown : QrLoginException()
|
data object Unknown : QrLoginException()
|
||||||
}
|
}
|
||||||
|
|||||||
+2
@@ -46,6 +46,8 @@ object QrErrorMapper {
|
|||||||
is RustHumanQrLoginException.SlidingSyncNotAvailable -> QrLoginException.SlidingSyncNotAvailable
|
is RustHumanQrLoginException.SlidingSyncNotAvailable -> QrLoginException.SlidingSyncNotAvailable
|
||||||
is RustHumanQrLoginException.CheckCodeAlreadySent -> QrLoginException.CheckCodeAlreadySent
|
is RustHumanQrLoginException.CheckCodeAlreadySent -> QrLoginException.CheckCodeAlreadySent
|
||||||
is RustHumanQrLoginException.CheckCodeCannotBeSent -> QrLoginException.CheckCodeCannotBeSent
|
is RustHumanQrLoginException.CheckCodeCannotBeSent -> QrLoginException.CheckCodeCannotBeSent
|
||||||
|
is RustHumanQrLoginException.ContinuationAlreadySent -> QrLoginException.ContinuationAlreadySent
|
||||||
|
is RustHumanQrLoginException.ContinuationCannotBeSent -> QrLoginException.ContinuationCannotBeSent
|
||||||
is RustHumanQrLoginException.UnsupportedQrCodeType -> QrLoginException.UnsupportedQrCodeType
|
is RustHumanQrLoginException.UnsupportedQrCodeType -> QrLoginException.UnsupportedQrCodeType
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+25
@@ -0,0 +1,25 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (c) 2026 Element Creations Ltd.
|
||||||
|
*
|
||||||
|
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial.
|
||||||
|
* Please see LICENSE files in the repository root for full details.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package io.element.android.libraries.matrix.impl.fixtures.fakes
|
||||||
|
|
||||||
|
import io.element.android.tests.testutils.lambda.lambdaError
|
||||||
|
import org.matrix.rustcomponents.sdk.ContinuationMessageSender
|
||||||
|
import org.matrix.rustcomponents.sdk.NoHandle
|
||||||
|
|
||||||
|
class FakeFfiContinuationMessageSender(
|
||||||
|
private val confirmResult: () -> Unit = { lambdaError() },
|
||||||
|
private val cancelResult: () -> Unit = { lambdaError() },
|
||||||
|
) : ContinuationMessageSender(NoHandle) {
|
||||||
|
override suspend fun confirm() {
|
||||||
|
confirmResult()
|
||||||
|
}
|
||||||
|
|
||||||
|
override suspend fun cancel() {
|
||||||
|
cancelResult()
|
||||||
|
}
|
||||||
|
}
|
||||||
+2
-1
@@ -13,6 +13,7 @@ import app.cash.turbine.test
|
|||||||
import com.google.common.truth.Truth.assertThat
|
import com.google.common.truth.Truth.assertThat
|
||||||
import io.element.android.libraries.matrix.api.linknewdevice.ErrorType
|
import io.element.android.libraries.matrix.api.linknewdevice.ErrorType
|
||||||
import io.element.android.libraries.matrix.api.linknewdevice.LinkDesktopStep
|
import io.element.android.libraries.matrix.api.linknewdevice.LinkDesktopStep
|
||||||
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiContinuationMessageSender
|
||||||
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiGrantLoginWithQrCodeHandler
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiGrantLoginWithQrCodeHandler
|
||||||
import io.element.android.libraries.matrix.test.QR_CODE_DATA
|
import io.element.android.libraries.matrix.test.QR_CODE_DATA
|
||||||
import kotlinx.coroutines.CompletableDeferred
|
import kotlinx.coroutines.CompletableDeferred
|
||||||
@@ -51,7 +52,7 @@ class RustLinkDesktopHandlerTest {
|
|||||||
listOf(
|
listOf(
|
||||||
GrantQrLoginProgress.Starting to LinkDesktopStep.Starting,
|
GrantQrLoginProgress.Starting to LinkDesktopStep.Starting,
|
||||||
GrantQrLoginProgress.SyncingSecrets to LinkDesktopStep.SyncingSecrets,
|
GrantQrLoginProgress.SyncingSecrets to LinkDesktopStep.SyncingSecrets,
|
||||||
GrantQrLoginProgress.WaitingForAuth("aVerificationUri")
|
GrantQrLoginProgress.WaitingForAuth("aVerificationUri", FakeFfiContinuationMessageSender())
|
||||||
to LinkDesktopStep.WaitingForAuth("aVerificationUri"),
|
to LinkDesktopStep.WaitingForAuth("aVerificationUri"),
|
||||||
GrantQrLoginProgress.EstablishingSecureChannel(1.toUByte(), "1")
|
GrantQrLoginProgress.EstablishingSecureChannel(1.toUByte(), "1")
|
||||||
to LinkDesktopStep.EstablishingSecureChannel(1.toUByte(), "1"),
|
to LinkDesktopStep.EstablishingSecureChannel(1.toUByte(), "1"),
|
||||||
|
|||||||
+2
-1
@@ -14,6 +14,7 @@ import com.google.common.truth.Truth.assertThat
|
|||||||
import io.element.android.libraries.matrix.api.linknewdevice.ErrorType
|
import io.element.android.libraries.matrix.api.linknewdevice.ErrorType
|
||||||
import io.element.android.libraries.matrix.api.linknewdevice.LinkMobileStep
|
import io.element.android.libraries.matrix.api.linknewdevice.LinkMobileStep
|
||||||
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiCheckCodeSender
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiCheckCodeSender
|
||||||
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiContinuationMessageSender
|
||||||
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiGrantLoginWithQrCodeHandler
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiGrantLoginWithQrCodeHandler
|
||||||
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiQrCodeData
|
import io.element.android.libraries.matrix.impl.fixtures.fakes.FakeFfiQrCodeData
|
||||||
import io.element.android.libraries.matrix.test.QR_CODE_DATA_RECIPROCATE
|
import io.element.android.libraries.matrix.test.QR_CODE_DATA_RECIPROCATE
|
||||||
@@ -52,7 +53,7 @@ class RustLinkMobileHandlerTest {
|
|||||||
listOf(
|
listOf(
|
||||||
GrantGeneratedQrLoginProgress.Starting to LinkMobileStep.Starting::class.java,
|
GrantGeneratedQrLoginProgress.Starting to LinkMobileStep.Starting::class.java,
|
||||||
GrantGeneratedQrLoginProgress.SyncingSecrets to LinkMobileStep.SyncingSecrets::class.java,
|
GrantGeneratedQrLoginProgress.SyncingSecrets to LinkMobileStep.SyncingSecrets::class.java,
|
||||||
GrantGeneratedQrLoginProgress.WaitingForAuth("aVerificationUri")
|
GrantGeneratedQrLoginProgress.WaitingForAuth("aVerificationUri", FakeFfiContinuationMessageSender())
|
||||||
to LinkMobileStep.WaitingForAuth::class.java,
|
to LinkMobileStep.WaitingForAuth::class.java,
|
||||||
GrantGeneratedQrLoginProgress.QrScanned(FakeFfiCheckCodeSender())
|
GrantGeneratedQrLoginProgress.QrScanned(FakeFfiCheckCodeSender())
|
||||||
to LinkMobileStep.QrScanned::class.java,
|
to LinkMobileStep.QrScanned::class.java,
|
||||||
|
|||||||
Reference in New Issue
Block a user