Last active
November 28, 2018 00:52
-
-
Save DiegoGSantos/cb163d381b16330e5ecae632b7860401 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
@Before | |
fun setUpTest() { | |
MockitoAnnotations.initMocks(this) | |
} | |
@Test | |
fun test() { | |
Mockito.`when`(mockRepository.getList(anyInt(),anyString())).thenReturn(expectedValue) | |
presenter.loadList() | |
verify(mockView, times(1)).showLoading() | |
verify(mockView, times(1)).hideLoading() | |
verify(mockView, times(1)).onListLoaded(any()) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment