-
Notifications
You must be signed in to change notification settings - Fork 29
Open
Description
For tests, Schedulers.immediate() is used instead of Schedulers.io() and Schedulers.mainThread(). It makes impossible to test that repoListPresenter.onSearchButtonClick() doesn't call view.hideLoading() until it loads result from the model.
The current RepoListPresenterTest.testShowLoading() show look like this:
@Test
public void testShowLoading() {
repoListPresenter.onSearchButtonClick();
verify(mockView).showLoading();
verify(mockView, never()).hideLoading();
}
But it's impossible now. Invocation of repoListPresenter.onSearchButtonClick() is blocking and will trigger view.hideLoading() upon completion.
Metadata
Metadata
Assignees
Labels
No labels