@Test public void testGetAllCategories() { List<String> expected = Arrays.asList(new String[]{"CATEGORY_1", "CATEGORY_2", "CATEGORY_3"}); when(systemCodesDao.getAllCategories()).thenReturn(expected); List<String> actual = systemCodesService.getAllCategories(); verify(systemCodesDao).getAllCategories(); assertEquals(expected, actual); }
public List<String> getAllCategories() { return getSystemCodesDao().getAllCategories(); }
SystemCodesServiceImpl extends BaseCrudServiceImpl<SystemCodes> implements SystemCodesService { public List<String> getAllCategories() { return getSystemCodesDao().getAllCategories(); } }
SystemCodesServiceImpl extends BaseCrudServiceImpl<SystemCodes> implements SystemCodesService { public List<String> getAllCategories() { return getSystemCodesDao().getAllCategories(); }  }
SystemCodesServiceImpl extends BaseCrudServiceImpl<SystemCodes> implements SystemCodesService { public List<String> getAllCategories() { return getSystemCodesDao().getAllCategories(); }  List<String> getAllCategories(); SystemCodes findByKey(SystemCodes systemCodes); SystemCodes findByKey(String systemCodes); List<SystemCodes> findSystemCodesByCategory(String category); List<String> getAllCategoriesExcept(String... categories); SystemCodesDao getSystemCodesDao(); @Override boolean isDuplicateKey(SystemCodes systemCodes); }
SystemCodesServiceImpl extends BaseCrudServiceImpl<SystemCodes> implements SystemCodesService { public List<String> getAllCategories() { return getSystemCodesDao().getAllCategories(); }  List<String> getAllCategories(); SystemCodes findByKey(SystemCodes systemCodes); SystemCodes findByKey(String systemCodes); List<SystemCodes> findSystemCodesByCategory(String category); List<String> getAllCategoriesExcept(String... categories); SystemCodesDao getSystemCodesDao(); @Override boolean isDuplicateKey(SystemCodes systemCodes);  }