@Test public void testGoToPosts() { when(wordPressService.listCategories()) .thenReturn(categoryResponse(3)); CategoryListModel categoryListModel = viewModel.initAndResume(); viewModel.goToPosts(1); verify(navigator).openPostList(PostListArgument.create(categoryListModel.get(1))); }
public void goToPosts(int position) { Category category = model.get(position); navigator.openPostList(PostListArgument.create(category)); }
CategoryListViewModel extends RxListViewModel<Void, CategoryListModel> { public void goToPosts(int position) { Category category = model.get(position); navigator.openPostList(PostListArgument.create(category)); } }
CategoryListViewModel extends RxListViewModel<Void, CategoryListModel> { public void goToPosts(int position) { Category category = model.get(position); navigator.openPostList(PostListArgument.create(category)); } @Inject  CategoryListViewModel(); }
CategoryListViewModel extends RxListViewModel<Void, CategoryListModel> { public void goToPosts(int position) { Category category = model.get(position); navigator.openPostList(PostListArgument.create(category)); } @Inject  CategoryListViewModel(); void goToPosts(int position); }
CategoryListViewModel extends RxListViewModel<Void, CategoryListModel> { public void goToPosts(int position) { Category category = model.get(position); navigator.openPostList(PostListArgument.create(category)); } @Inject  CategoryListViewModel(); void goToPosts(int position);  }