AppsPresenter { protected List<App> sort(List<App> apps) { Collections.sort(apps); return apps; } AppsPresenter(AppsActivity appsActivity, AppsProvider appsProvider); void showAllApps(); void filterApps(String text);  }
@Test public void should_sort() throws Exception { List<App> apps = Arrays.asList(new App("BBB"), new App("AAA")); List<App> result = appsPresenter.sort(apps); assertThat(result).hasSize(2); assertThat(result.get(0).title).isEqualTo("AAA"); assertThat(result.get(1).title).isEqualTo("BBB"); }