From 7027b33eb41947e6799392d392283b09110158d1 Mon Sep 17 00:00:00 2001 From: aribeiro Date: Wed, 17 Jun 2020 14:20:46 +0100 Subject: Add Node Filter Business Logic Unit Tests Issue-ID: SDC-3125 Signed-off-by: aribeiro Change-Id: I80c755f4fffa813396ceb85c6aa7fde5b32590cd --- .../model/jsonjanusgraph/operations/NodeFilterOperation.java | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'catalog-model/src') diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/NodeFilterOperation.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/NodeFilterOperation.java index 7ed7818ab4..5f0284a159 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/NodeFilterOperation.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsonjanusgraph/operations/NodeFilterOperation.java @@ -97,18 +97,20 @@ public class NodeFilterOperation extends BaseOperation { return addOrUpdateNodeFilter(true, serviceId, componentInstanceId, nodeFilterDataDefinition); } - public Either addNewProperty(String serviceId, - String componentInstanceId, CINodeFilterDataDefinition nodeFilterDataDefinition, - RequirementNodeFilterPropertyDataDefinition requirementNodeFilterPropertyDataDefinition) { + public Either addNewProperty( + final String componentId, final String componentInstanceId, + final CINodeFilterDataDefinition nodeFilterDataDefinition, + final RequirementNodeFilterPropertyDataDefinition requirementNodeFilterPropertyDataDefinition) { + ListDataDefinition properties = - nodeFilterDataDefinition.getProperties(); + nodeFilterDataDefinition.getProperties(); if (properties == null) { properties = new ListDataDefinition<>(); nodeFilterDataDefinition.setProperties(properties); } properties.getListToscaDataDefinition().add(requirementNodeFilterPropertyDataDefinition); nodeFilterDataDefinition.setProperties(properties); - return addOrUpdateNodeFilter(true, serviceId, componentInstanceId, nodeFilterDataDefinition); + return addOrUpdateNodeFilter(true, componentId, componentInstanceId, nodeFilterDataDefinition); } public Either updateProperties(String serviceId, -- cgit 1.2.3-korg