diff options
Diffstat (limited to 'appc-dispatcher/appc-command-executor')
2 files changed, 9 insertions, 11 deletions
diff --git a/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutionTask.java b/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutionTask.java index 97d77a9d8..9757430d8 100644 --- a/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutionTask.java +++ b/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutionTask.java @@ -31,6 +31,7 @@ import org.mockito.Mockito; import org.mockito.invocation.InvocationOnMock; import org.mockito.stubbing.Answer; import org.openecomp.appc.domainmodel.lcm.*; +import org.openecomp.appc.domainmodel.lcm.Flags.Mode; import org.openecomp.appc.executor.impl.CommandTask; import org.openecomp.appc.executor.impl.CommandTaskFactory; import org.openecomp.appc.executor.impl.LCMCommandTask; @@ -179,8 +180,7 @@ public class TestCommandExecutionTask { CommonHeader commonHeader = new CommonHeader(); requestContext.setCommonHeader(commonHeader); responseContext.setCommonHeader(commonHeader); - Flags flags = new Flags(); - commonHeader.setFlags(flags); + commonHeader.setFlags(new Flags(null, false, 0)); ActionIdentifiers actionIdentifiers = new ActionIdentifiers(); requestContext.setActionIdentifiers(actionIdentifiers); VNFContext vnfContext = new VNFContext(); @@ -232,7 +232,7 @@ public class TestCommandExecutionTask { ResponseContext responseContext = createResponseContextWithSuObjects(); commandExecutorInput.setResponseContext(responseContext); - requestContext.getCommonHeader().getFlags().setTtl(ttl); + requestContext.getCommonHeader().setFlags(new Flags(null, false, ttl)); requestContext.getCommonHeader().setApiVer(apiVersion); requestContext.getCommonHeader().setTimestamp(timeStamp); requestContext.getCommonHeader().setRequestId(requestId); @@ -258,8 +258,7 @@ public class TestCommandExecutionTask { runtimeContext.setRequestContext(requestContext); CommonHeader commonHeader = new CommonHeader(); requestContext.setCommonHeader(commonHeader); - Flags flags = new Flags(); - commonHeader.setFlags(flags); + commonHeader.setFlags(new Flags(null, false, 0)); ActionIdentifiers actionIdentifiers = new ActionIdentifiers(); requestContext.setActionIdentifiers(actionIdentifiers); VNFContext vnfContext = new VNFContext(); @@ -271,10 +270,9 @@ public class TestCommandExecutionTask { private ResponseContext createResponseContextWithSuObjects(){ ResponseContext responseContext = new ResponseContext(); CommonHeader commonHeader = new CommonHeader(); - Flags flags = new Flags(); responseContext.setCommonHeader(commonHeader); responseContext.setStatus(new Status(0, null)); - commonHeader.setFlags(flags); + commonHeader.setFlags(new Flags(null, false, 0)); return responseContext; } diff --git a/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutor.java b/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutor.java index ba4221509..bb4e39109 100644 --- a/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutor.java +++ b/appc-dispatcher/appc-command-executor/appc-command-executor-core/src/test/java/org/openecomp/appc/executor/TestCommandExecutor.java @@ -30,6 +30,7 @@ import org.junit.Before; import org.junit.Test; import org.mockito.Mockito; import org.openecomp.appc.domainmodel.lcm.*; +import org.openecomp.appc.domainmodel.lcm.Flags.Mode; import org.openecomp.appc.exceptions.APPCException; import org.openecomp.appc.executionqueue.ExecutionQueueService; import org.openecomp.appc.executor.impl.CommandExecutorImpl; @@ -114,9 +115,9 @@ public class TestCommandExecutor { private RuntimeContext pouplateCommandExecutorInput(String vnfType, int ttl, String vnfVersion, Date timeStamp, String apiVersion, String requestId, String originatorID, String subRequestID, VNFOperation action, String vnfId , String payload){ - RuntimeContext commandExecutorInput = createCommandExecutorInputWithSubObjects(); + RuntimeContext commandExecutorInput = createCommandExecutorInputWithSubObjects(); RequestContext requestContext = commandExecutorInput.getRequestContext(); - requestContext.getCommonHeader().getFlags().setTtl(ttl); + requestContext.getCommonHeader().setFlags(new Flags(null, false, ttl)); requestContext.getCommonHeader().setApiVer(apiVersion); requestContext.getCommonHeader().setTimestamp(timeStamp); requestContext.getCommonHeader().setRequestId(requestId); @@ -138,8 +139,7 @@ public class TestCommandExecutor { runtimeContext.setRequestContext(requestContext); CommonHeader commonHeader = new CommonHeader(); requestContext.setCommonHeader(commonHeader); - Flags flags = new Flags(); - commonHeader.setFlags(flags); + commonHeader.setFlags(new Flags(null, false, 0)); ActionIdentifiers actionIdentifiers = new ActionIdentifiers(); requestContext.setActionIdentifiers(actionIdentifiers); VNFContext vnfContext = new VNFContext(); |