From a544201e0f2ca992b7a4533e6e1dc475152372a6 Mon Sep 17 00:00:00 2001 From: Victor Andreasson Date: Sun, 8 Sep 2024 19:34:55 +0200 Subject: [PATCH] Another sleep in an Espresso test --- .../androidTest/java/com/orgzly/android/espresso/GitRepoTest.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/src/androidTest/java/com/orgzly/android/espresso/GitRepoTest.kt b/app/src/androidTest/java/com/orgzly/android/espresso/GitRepoTest.kt index 654f7a30..7ebd0772 100644 --- a/app/src/androidTest/java/com/orgzly/android/espresso/GitRepoTest.kt +++ b/app/src/androidTest/java/com/orgzly/android/espresso/GitRepoTest.kt @@ -1,5 +1,6 @@ package com.orgzly.android.espresso +import android.os.SystemClock import androidx.core.net.toUri import androidx.test.core.app.ActivityScenario import androidx.test.espresso.Espresso @@ -66,6 +67,7 @@ class GitRepoTest : OrgzlyTest() { assertEquals(3, dataRepository.getBooks().size) ActivityScenario.launch(MainActivity::class.java).use { sync() + SystemClock.sleep(2000) onBook(0, R.id.item_book_link_repo).check(ViewAssertions.matches(withText(repo.url))) onBook(1, R.id.item_book_link_repo).check(ViewAssertions.matches(withText(repo.url))) onBook(2, R.id.item_book_link_repo).check(ViewAssertions.matches(withText(repo.url)))