Skip to content

Commit

Permalink
~
Browse files Browse the repository at this point in the history
  • Loading branch information
max-kammerer committed May 26, 2024
1 parent 517faa1 commit 06c9380
Showing 1 changed file with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ import androidx.test.espresso.action.GeneralSwipeAction
import androidx.test.espresso.action.Press
import androidx.test.espresso.action.Swipe
import androidx.test.espresso.action.Tap
import androidx.test.espresso.assertion.ViewAssertions
import androidx.test.espresso.matcher.ViewMatchers.isDisplayed
import androidx.test.espresso.matcher.ViewMatchers.withId
import androidx.test.filters.SdkSuppress
import org.junit.Assert.assertEquals
Expand Down Expand Up @@ -41,12 +43,16 @@ open class PageSeekerTest(bookDescription: BookFile): BaseViewerActivityTest(boo

private fun testGotoSwipe(swipe: Swipe) {
configure()
Thread.sleep(1000)
device.waitForIdle()
openGoTo()
val lastPageNumber = lastPageNumber0

onView(withId(R.id.page_picker_seeker)).check(ViewAssertions.matches(isDisplayed()))

onView(withId(R.id.page_picker_seeker)).perform(GeneralClickAction(Tap.SINGLE, GeneralLocation.CENTER_LEFT, Press.PINPOINT, InputDevice.SOURCE_TOUCHSCREEN,
MotionEvent.BUTTON_PRIMARY))

onView(withId(R.id.page_picker_seeker)).check(ViewAssertions.matches(isDisplayed()))
onView(withId(R.id.page_picker_seeker)).perform(GeneralSwipeAction(
swipe, GeneralLocation.CENTER_LEFT,
GeneralLocation.CENTER_RIGHT, Press.PINPOINT
Expand Down

0 comments on commit 06c9380

Please sign in to comment.