Created
June 15, 2023 21:50
-
-
Save tugceaktepe/7788822649e56addcf4c831c917fe43f to your computer and use it in GitHub Desktop.
Test for receiving error from api
This file contains 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 | |
fun showErrorWhenMovieLoadFailed() { | |
mockWebServer.dispatcher = MockServerDispatcher().ErrorDispatcher() | |
val scenario = launchActivity<MainActivity>() | |
onView(withText(Constants.ERROR_MESSAGE)).check(matches(isDisplayed())) | |
scenario.close() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment