@Test
public void test27deleteXModuleDefPermission() {

	Long moduleId=Long.valueOf(1);
	XXUserPermissionDao xUserPermissionDao = Mockito.mock(XXUserPermissionDao.class);
	XXGroupPermissionDao xGroupPermissionDao = Mockito.mock(XXGroupPermissionDao.class);
	Mockito.when(daoManager.getXXUserPermission()).thenReturn(xUserPermissionDao);
	Mockito.when(daoManager.getXXGroupPermission()).thenReturn(xGroupPermissionDao);
	Mockito.doNothing().when(xUserPermissionDao).deleteByModuleId(moduleId);
	Mockito.doNothing().when(xGroupPermissionDao).deleteByModuleId(moduleId);
	Mockito.when(xModuleDefService.deleteResource(1L)).thenReturn(true);
	xUserMgr.deleteXModuleDefPermission(1L, true);
	Mockito.verify(xModuleDefService).deleteResource(1L);
}