IncidentSearchPresenter extends RecordSearchPresenter { public List<String> getViolenceTypeList() { return incidentFormService.getViolenceTypeList(); } @Inject  IncidentSearchPresenter(IncidentService incidentService, IncidentFormService incidentFormService); List<String> getViolenceTypeList(); List<String> getIncidentLocationList();  }
@Test public void should_return_list_when_get_violence_type_list() throws Exception { List<String> list = new ArrayList<>(); when(incidentFormService.getViolenceTypeList()).thenReturn(list); assertThat("Should return same list", incidentSearchPresenter.getViolenceTypeList(), is(list)); }