@Test
public void test22getService() throws Exception {

	RangerService rangerService = rangerService();
	XXService xService = xService();
	XXServiceDao xServiceDao = Mockito.mock(XXServiceDao.class);
	Mockito.when(daoManager.getXXService()).thenReturn(xServiceDao);
	Mockito.when(xServiceDao.getById(Id)).thenReturn(xService);
	Mockito.when(!bizUtil.hasAccess(xService, null)).thenReturn(true);
	Mockito.when(svcService.getPopulatedViewObject(xService)).thenReturn(
			rangerService);
	RangerService dbRangerService = serviceDBStore.getService(Id);
	Assert.assertNotNull(dbRangerService);
	Assert.assertEquals(dbRangerService, rangerService);
	Assert.assertEquals(dbRangerService.getCreatedBy(),
			rangerService.getCreatedBy());
	Assert.assertEquals(dbRangerService.getDescription(),
			rangerService.getDescription());
	Assert.assertEquals(dbRangerService.getGuid(), rangerService.getGuid());
	Assert.assertEquals(dbRangerService.getName(), rangerService.getName());
	Assert.assertEquals(dbRangerService.getType(), rangerService.getType());
	Assert.assertEquals(dbRangerService.getUpdatedBy(),
			rangerService.getUpdatedBy());
	Assert.assertEquals(dbRangerService.getConfigs(),
			rangerService.getConfigs());
	Assert.assertEquals(dbRangerService.getCreateTime(),
			rangerService.getCreateTime());
	Assert.assertEquals(dbRangerService.getId(), rangerService.getId());
	Assert.assertEquals(dbRangerService.getPolicyVersion(),
			rangerService.getPolicyVersion());
	Assert.assertEquals(dbRangerService.getVersion(),
			rangerService.getVersion());
	Assert.assertEquals(dbRangerService.getPolicyUpdateTime(),
			rangerService.getPolicyUpdateTime());
	Mockito.verify(daoManager).getXXService();
	Mockito.verify(bizUtil).hasAccess(xService, null);
	Mockito.verify(svcService).getPopulatedViewObject(xService);
}