From c087becee10551ca89c031d9c8bc8f97b3c86e26 Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Wed, 30 Oct 2024 21:00:52 +0100 Subject: [PATCH] Fix test `present - with CallType RoomCall sets call as active, loads URL, runs WidgetDriver and notifies the other clients a call started` not passing. --- .../android/services/analytics/test/FakeScreenTracker.kt | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/services/analytics/test/src/main/kotlin/io/element/android/services/analytics/test/FakeScreenTracker.kt b/services/analytics/test/src/main/kotlin/io/element/android/services/analytics/test/FakeScreenTracker.kt index 7065016204..4ac0f7ffd2 100644 --- a/services/analytics/test/src/main/kotlin/io/element/android/services/analytics/test/FakeScreenTracker.kt +++ b/services/analytics/test/src/main/kotlin/io/element/android/services/analytics/test/FakeScreenTracker.kt @@ -8,6 +8,7 @@ package io.element.android.services.analytics.test import androidx.compose.runtime.Composable +import androidx.compose.runtime.LaunchedEffect import im.vector.app.features.analytics.plan.MobileScreen import io.element.android.services.analytics.api.ScreenTracker import io.element.android.tests.testutils.lambda.lambdaError @@ -17,6 +18,8 @@ class FakeScreenTracker( ) : ScreenTracker { @Composable override fun TrackScreen(screen: MobileScreen.ScreenName) { - trackScreenLambda(screen) + LaunchedEffect(Unit) { + trackScreenLambda(screen) + } } }