PrizePresenter extends RxPresenter<PrizeView, ArrayList<Prize> > implements Comparator<Prize> { @Override void onNext(ArrayList<Prize> prizes) { Collections.sort(prizes, this); if (isViewAttached()) { getView().showPrizes(prizes); } }  void updatePrizes(); @Override int compare(Prize lhs, Prize rhs);  }
@Test public void testOnNext() throws Exception { ArrayList<Prize> prizes = new ArrayList<>(); prizes.add(new Prize()); presenter.onNext(prizes); verify(view).showPrizes(prizes); }