Created
September 7, 2016 17:45
-
-
Save heitorcolangelo/98e0552095862fdff677d2d7d13ccd2a to your computer and use it in GitHub Desktop.
UserDetailsActivityTest - runtime permission error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Test | |
public void clickOnPhone_shouldStartPhoneIntent() { | |
mActivityRule.launchActivity(createIntent(false)); | |
Intents.init(); | |
intending(hasAction(Intent.ACTION_CALL)) | |
.respondWith(new Instrumentation.ActivityResult(Activity.RESULT_OK, new Intent())); | |
onView(withId(R.id.user_details_phone)).perform(scrollTo(), click()); | |
intended(hasAction(Intent.ACTION_CALL)); | |
Intents.release(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment