Last active
July 21, 2022 19:23
-
-
Save Raiden18/b8c6071afb2ba88159677a73a5589e89 to your computer and use it in GitHub Desktop.
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 `Should show content state if user clicks on retry button after loading data with error`() = runTest { | |
val throwable = Throwable() | |
val viewModel = ViewModelBuilder() | |
.withDataLoadedWithError(throwable) | |
.build(testScheduler) | |
//Replaced with Cases | |
Cases(viewModel) | |
.nowDataIsLoadedSuccessfully(dataToLoad)) | |
.userClicksOnRetryButton() | |
assertThat(viewModel) | |
.contentIsShow(dataToLoad) | |
.loaderIsHidden() | |
.errorIsHidden() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment