mirror of
https://github.com/fork-maintainers/iceraven-browser
synced 2024-11-03 23:15:31 +00:00
[fenix] For https://github.com/mozilla-mobile/fenix/issues/18481: waits for url to be visible in TestHelper.verifyUrl() (https://github.com/mozilla-mobile/fenix/pull/18498)
This commit is contained in:
parent
a862baeda2
commit
be560986e1
@ -28,6 +28,7 @@ import kotlinx.coroutines.runBlocking
|
||||
import org.hamcrest.CoreMatchers
|
||||
import org.hamcrest.CoreMatchers.allOf
|
||||
import org.mozilla.fenix.R
|
||||
import org.mozilla.fenix.helpers.TestAssetHelper.waitingTime
|
||||
import org.mozilla.fenix.helpers.ext.waitNotNull
|
||||
import org.mozilla.fenix.helpers.idlingresource.NetworkConnectionIdlingResource
|
||||
import org.mozilla.fenix.ui.robots.mDevice
|
||||
@ -88,6 +89,7 @@ object TestHelper {
|
||||
|
||||
fun verifyUrl(urlSubstring: String, resourceName: String, resId: Int) {
|
||||
waitUntilObjectIsFound(resourceName)
|
||||
mDevice.findObject(UiSelector().text(urlSubstring)).waitForExists(waitingTime)
|
||||
onView(withId(resId)).check(ViewAssertions.matches(withText(CoreMatchers.containsString(urlSubstring))))
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user