Skip to content

Commit c20111c

Browse files
committed
test: wait for onboarding state in device tests
1 parent 7fdb940 commit c20111c

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎app/src/androidTest/kotlin/org/qownnotes/mobile/AppLaunchTest.kt‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ package org.qownnotes.mobile
33
import androidx.compose.ui.test.assertIsDisplayed
44
import androidx.compose.ui.test.junit4.createAndroidComposeRule
55
import androidx.compose.ui.test.onAllNodesWithText
6+
import androidx.compose.ui.test.onAllNodesWithTag
67
import androidx.compose.ui.test.onNodeWithTag
78
import androidx.compose.ui.test.onNodeWithText
89
import androidx.compose.ui.test.performClick
@@ -30,7 +31,9 @@ class AppLaunchTest {
3031
@Before
3132
fun resetApplication() {
3233
runBlocking { application.reset() }
33-
composeRule.waitForIdle()
34+
composeRule.waitUntil(timeoutMillis = 10_000) {
35+
composeRule.onAllNodesWithTag("onboarding").fetchSemanticsNodes().isNotEmpty()
36+
}
3437
}
3538

3639
@Test

0 commit comments

Comments
 (0)