Skip to content

Instantly share code, notes, and snippets.

@igor-brishkoski
Created January 13, 2019 20:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save igor-brishkoski/d734eabd4ae39aad6ac4c075b69d16c7 to your computer and use it in GitHub Desktop.
Save igor-brishkoski/d734eabd4ae39aad6ac4c075b69d16c7 to your computer and use it in GitHub Desktop.
fun ViewInteraction.click(): ViewInteraction =
perform(ViewActions.click())
fun ViewInteraction.typeText(text: String): ViewInteraction =
perform(ViewActions.typeText(text), ViewActions.closeSoftKeyboard())
fun ViewInteraction.isTextDisplayed(text: String): ViewInteraction =
check(ViewAssertions.matches(ViewMatchers.withText(text)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment