summaryrefslogtreecommitdiffstats
path: root/plugins/plugins-executor/plugins-executor-javascript
diff options
context:
space:
mode:
authora.sreekumar <ajith.sreekumar@bell.ca>2021-06-29 13:57:14 +0100
committera.sreekumar <ajith.sreekumar@bell.ca>2021-07-02 16:03:51 +0100
commit5f0ec1c2d95c377fbec428f11464e93fe442b5ef (patch)
tree4aef07097fa4d64550db116a1b1b4acd1aa42590 /plugins/plugins-executor/plugins-executor-javascript
parentba55109db1e5eea013dcffd1be29cf06fe2bbcb1 (diff)
Cleanup input & outputFields from Task definition
1) Remove the usage of inputField and outputField from Task definition. 2) Fix issues around populating events to task in case of State Finalizer Logic. Change-Id: Ief17f400729410b83c6b7c665980d443e0cf6f28 Issue-ID: POLICY-3336 Signed-off-by: a.sreekumar <ajith.sreekumar@bell.ca>
Diffstat (limited to 'plugins/plugins-executor/plugins-executor-javascript')
-rw-r--r--plugins/plugins-executor/plugins-executor-javascript/src/test/java/org/onap/policy/apex/plugins/executor/javascript/JavascriptTaskExecutorTest.java7
1 files changed, 2 insertions, 5 deletions
diff --git a/plugins/plugins-executor/plugins-executor-javascript/src/test/java/org/onap/policy/apex/plugins/executor/javascript/JavascriptTaskExecutorTest.java b/plugins/plugins-executor/plugins-executor-javascript/src/test/java/org/onap/policy/apex/plugins/executor/javascript/JavascriptTaskExecutorTest.java
index fbf7db864..215491d4e 100644
--- a/plugins/plugins-executor/plugins-executor-javascript/src/test/java/org/onap/policy/apex/plugins/executor/javascript/JavascriptTaskExecutorTest.java
+++ b/plugins/plugins-executor/plugins-executor-javascript/src/test/java/org/onap/policy/apex/plugins/executor/javascript/JavascriptTaskExecutorTest.java
@@ -166,19 +166,16 @@ public class JavascriptTaskExecutorTest {
internalContext.getContextAlbums().put(contextAlbum.getKey(), contextAlbum);
task.getContextAlbumReferences().add(contextAlbum.getKey());
- String parKey0 = "par0";
- task.getOutputFields().put(parKey0, null);
- String parKey1 = "par1";
- task.getOutputFields().put(parKey1, null);
jte.setContext(null, task, internalContext);
-
+ String parKey0 = "par0";
Map<String, Object> incomingParameters = new HashMap<>();
incomingParameters.put(parKey0, "value0");
AxEvent inEvent = new AxEvent();
inEvent.setParameterMap(Map.of(parKey0, new AxField()));
task.setInputEvent(inEvent);
+ String parKey1 = "par1";
AxEvent outEvent = new AxEvent();
outEvent.setParameterMap(Map.of(parKey0, new AxField(), parKey1, new AxField()));
final String eventName = "event1";