@Test public void testLoadTopicNodesSuccess() throws Exception { Map<TopicNodeCategory, List<TopicNode>> nodesMap = mock(Map.class); when(mDataManager.getTopicNodes()).thenReturn(Single.just(nodesMap)); mPresenter.loadTopicNodes(); verify(mView).showNodes(nodesMap); }
public void loadTopicNodes() { final ITopicCreatorView view = getView(); Disposable disposable = mDataManager.getTopicNodes() .subscribe(view::showNodes, throwable -> { }); addDisposable(disposable); }
TopicCreatorPresenter extends BasePresenter<ITopicCreatorView> { public void loadTopicNodes() { final ITopicCreatorView view = getView(); Disposable disposable = mDataManager.getTopicNodes() .subscribe(view::showNodes, throwable -> { }); addDisposable(disposable); } }
TopicCreatorPresenter extends BasePresenter<ITopicCreatorView> { public void loadTopicNodes() { final ITopicCreatorView view = getView(); Disposable disposable = mDataManager.getTopicNodes() .subscribe(view::showNodes, throwable -> { }); addDisposable(disposable); } @Inject  TopicCreatorPresenter(DataManager dataManager); }
TopicCreatorPresenter extends BasePresenter<ITopicCreatorView> { public void loadTopicNodes() { final ITopicCreatorView view = getView(); Disposable disposable = mDataManager.getTopicNodes() .subscribe(view::showNodes, throwable -> { }); addDisposable(disposable); } @Inject  TopicCreatorPresenter(DataManager dataManager); void loadTopicNodes(); void createTopic(); }
TopicCreatorPresenter extends BasePresenter<ITopicCreatorView> { public void loadTopicNodes() { final ITopicCreatorView view = getView(); Disposable disposable = mDataManager.getTopicNodes() .subscribe(view::showNodes, throwable -> { }); addDisposable(disposable); } @Inject  TopicCreatorPresenter(DataManager dataManager); void loadTopicNodes(); void createTopic();  }