@Test public void testExecute_WhenDeleteNetworkElementSucceeds_DeleteSFCAndNullsSGNetworkElementId() throws Exception { DeleteServiceFunctionChainTask deleteTask = this.task.create(SG_SFC_UNBIND_DELETE_SFC); mockDeleteNetworkElement(SG_SFC_UNBIND_DELETE_SFC, new NetworkElementImpl(SG_SFC_UNBIND_DELETE_SFC.getNetworkElementId()), null); deleteTask.execute(); assertEquals( SecurityGroupEntityMgr.findById(this.em, SG_SFC_UNBIND_DELETE_SFC.getId()).getNetworkElementId(), null); }
public DeleteServiceFunctionChainTask create(SecurityGroup securityGroup) { DeleteServiceFunctionChainTask task = new DeleteServiceFunctionChainTask(); task.securityGroup = securityGroup; task.apiFactory = this.apiFactory; task.name = task.getName(); task.dbConnectionManager = this.dbConnectionManager; task.txBroadcastUtil = this.txBroadcastUtil; return task; }
DeleteServiceFunctionChainTask extends TransactionalTask { public DeleteServiceFunctionChainTask create(SecurityGroup securityGroup) { DeleteServiceFunctionChainTask task = new DeleteServiceFunctionChainTask(); task.securityGroup = securityGroup; task.apiFactory = this.apiFactory; task.name = task.getName(); task.dbConnectionManager = this.dbConnectionManager; task.txBroadcastUtil = this.txBroadcastUtil; return task; } }
DeleteServiceFunctionChainTask extends TransactionalTask { public DeleteServiceFunctionChainTask create(SecurityGroup securityGroup) { DeleteServiceFunctionChainTask task = new DeleteServiceFunctionChainTask(); task.securityGroup = securityGroup; task.apiFactory = this.apiFactory; task.name = task.getName(); task.dbConnectionManager = this.dbConnectionManager; task.txBroadcastUtil = this.txBroadcastUtil; return task; }  }
DeleteServiceFunctionChainTask extends TransactionalTask { public DeleteServiceFunctionChainTask create(SecurityGroup securityGroup) { DeleteServiceFunctionChainTask task = new DeleteServiceFunctionChainTask(); task.securityGroup = securityGroup; task.apiFactory = this.apiFactory; task.name = task.getName(); task.dbConnectionManager = this.dbConnectionManager; task.txBroadcastUtil = this.txBroadcastUtil; return task; }  DeleteServiceFunctionChainTask create(SecurityGroup securityGroup); @Override void executeTransaction(EntityManager em); @Override Set<LockObjectReference> getObjects(); @Override String getName(); }
DeleteServiceFunctionChainTask extends TransactionalTask { public DeleteServiceFunctionChainTask create(SecurityGroup securityGroup) { DeleteServiceFunctionChainTask task = new DeleteServiceFunctionChainTask(); task.securityGroup = securityGroup; task.apiFactory = this.apiFactory; task.name = task.getName(); task.dbConnectionManager = this.dbConnectionManager; task.txBroadcastUtil = this.txBroadcastUtil; return task; }  DeleteServiceFunctionChainTask create(SecurityGroup securityGroup); @Override void executeTransaction(EntityManager em); @Override Set<LockObjectReference> getObjects(); @Override String getName();  }