mirror of
https://github.com/fork-maintainers/iceraven-browser
synced 2024-11-09 19:10:42 +00:00
Closes 9291: Fix shortcutSearchEngineSettingsTest (#9292)
This commit is contained in:
parent
eaa69cf72b
commit
f8048462b5
@ -61,7 +61,6 @@ class SearchTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@Ignore("Temp disable flakey test - see: https://github.com/mozilla-mobile/fenix/issues/5462")
|
|
||||||
fun shortcutSearchEngineSettingsTest() {
|
fun shortcutSearchEngineSettingsTest() {
|
||||||
homeScreen {
|
homeScreen {
|
||||||
}.openSearch {
|
}.openSearch {
|
||||||
|
@ -9,7 +9,9 @@ package org.mozilla.fenix.ui.robots
|
|||||||
import androidx.recyclerview.widget.RecyclerView
|
import androidx.recyclerview.widget.RecyclerView
|
||||||
import androidx.test.espresso.Espresso.onView
|
import androidx.test.espresso.Espresso.onView
|
||||||
import androidx.test.espresso.ViewInteraction
|
import androidx.test.espresso.ViewInteraction
|
||||||
|
import androidx.test.espresso.action.ViewActions
|
||||||
import androidx.test.espresso.action.ViewActions.click
|
import androidx.test.espresso.action.ViewActions.click
|
||||||
|
import androidx.test.espresso.action.ViewActions.closeSoftKeyboard
|
||||||
import androidx.test.espresso.action.ViewActions.typeText
|
import androidx.test.espresso.action.ViewActions.typeText
|
||||||
import androidx.test.espresso.assertion.ViewAssertions.matches
|
import androidx.test.espresso.assertion.ViewAssertions.matches
|
||||||
import androidx.test.espresso.contrib.RecyclerViewActions
|
import androidx.test.espresso.contrib.RecyclerViewActions
|
||||||
@ -21,7 +23,6 @@ import androidx.test.platform.app.InstrumentationRegistry
|
|||||||
import androidx.test.uiautomator.By
|
import androidx.test.uiautomator.By
|
||||||
import androidx.test.uiautomator.UiDevice
|
import androidx.test.uiautomator.UiDevice
|
||||||
import androidx.test.uiautomator.UiObject
|
import androidx.test.uiautomator.UiObject
|
||||||
import androidx.test.uiautomator.UiScrollable
|
|
||||||
import androidx.test.uiautomator.UiSelector
|
import androidx.test.uiautomator.UiSelector
|
||||||
import androidx.test.uiautomator.Until
|
import androidx.test.uiautomator.Until
|
||||||
import org.hamcrest.CoreMatchers.allOf
|
import org.hamcrest.CoreMatchers.allOf
|
||||||
@ -79,10 +80,12 @@ class SearchRobot {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun scrollToSearchEngineSettings(): UiScrollable {
|
fun scrollToSearchEngineSettings() {
|
||||||
val appView = UiScrollable(UiSelector().scrollable(true))
|
// Soft keyboard is visible on screen on view access; hide it
|
||||||
appView.scrollTextIntoView("Search engine settings")
|
onView(allOf(withId(R.id.search_layout))).perform(
|
||||||
return appView
|
closeSoftKeyboard()
|
||||||
|
)
|
||||||
|
onView(allOf(withId(R.id.awesomeBar))).perform(ViewActions.swipeUp())
|
||||||
}
|
}
|
||||||
|
|
||||||
fun clickSearchEngineSettings() {
|
fun clickSearchEngineSettings() {
|
||||||
|
Loading…
Reference in New Issue
Block a user