/** Test the {@link EarlyAlertSuggestionServiceImpl#getAll(SortingAndPaging)} method. */ @Test public void testGetAll() { final List<EarlyAlertSuggestion> daoAll = new ArrayList<EarlyAlertSuggestion>(); daoAll.add(new EarlyAlertSuggestion()); expect(dao.getAll(isA(SortingAndPaging.class))) .andReturn(new PagingWrapper<EarlyAlertSuggestion>(daoAll)); replay(dao); final Collection<EarlyAlertSuggestion> all = service.getAll(new SortingAndPaging(ObjectStatus.ACTIVE)).getRows(); assertFalse("List should not have been empty.", all.isEmpty()); verify(dao); }