@Test
public void test16getServiceDefByNameNotNull() throws Exception {

	String name = "fdfdfds";
	XXServiceDefDao xServiceDefDao = Mockito.mock(XXServiceDefDao.class);
	XXServiceDef xServiceDef = Mockito.mock(XXServiceDef.class);
	RangerServiceDef serviceDef = new RangerServiceDef();
	Mockito.when(daoManager.getXXServiceDef()).thenReturn(xServiceDefDao);
	Mockito.when(xServiceDefDao.findByName(name)).thenReturn(xServiceDef);
	Mockito.when(serviceDefService.getPopulatedViewObject(xServiceDef))
			.thenReturn(serviceDef);
	RangerServiceDef dbServiceDef = serviceDBStore
			.getServiceDefByName(name);
	Assert.assertNotNull(dbServiceDef);
	Mockito.verify(daoManager).getXXServiceDef();
}