aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-be/src/test/java
diff options
context:
space:
mode:
Diffstat (limited to 'catalog-be/src/test/java')
-rw-r--r--catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java6
-rw-r--r--catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java9
2 files changed, 9 insertions, 6 deletions
diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java
index a475943735..7c81807777 100644
--- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java
+++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java
@@ -470,7 +470,8 @@ public class ComponentNodeFilterBusinessLogicTest extends BaseBusinessLogicMock
final List<String> constraints = requirementNodeFilterPropertyDataDefinition.getConstraints();
assertThrows(BusinessLogicException.class, () -> componentNodeFilterBusinessLogic
- .updateNodeFilter(componentId, componentInstanceId, constraints, true, ComponentTypeEnum.RESOURCE));
+ .updateNodeFilter(componentId, componentInstanceId, constraints, true, ComponentTypeEnum.RESOURCE,
+ NodeFilterConstraintType.PROPERTIES));
verify(toscaOperationFacade, times(1)).getToscaElement(componentId);
verify(nodeFilterValidator, times(1)).validateFilter(resource, componentInstanceId,
@@ -485,7 +486,8 @@ public class ComponentNodeFilterBusinessLogicTest extends BaseBusinessLogicMock
constraints, NodeFilterConstraintAction.UPDATE)).thenReturn(Either.left(true));
assertThrows(BusinessLogicException.class, () -> componentNodeFilterBusinessLogic
- .updateNodeFilter(componentId, componentInstanceId, constraints, true, ComponentTypeEnum.RESOURCE));
+ .updateNodeFilter(componentId, componentInstanceId, constraints, true, ComponentTypeEnum.RESOURCE,
+ NodeFilterConstraintType.PROPERTIES));
verify(toscaOperationFacade, times(1)).getToscaElement(componentId);
verify(nodeFilterValidator, times(1)).validateFilter(resource, componentInstanceId,
diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java
index 31cb1ac4e4..947a702db0 100644
--- a/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java
+++ b/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java
@@ -328,7 +328,8 @@ public class ComponentNodeFilterServletTest extends JerseyTest {
when(componentNodeFilterBusinessLogic
.updateNodeFilter(componentId, componentInstance, Collections.singletonList(constraint),
- true, ComponentTypeEnum.RESOURCE)).thenReturn(Optional.of(ciNodeFilterDataDefinition));
+ true, ComponentTypeEnum.RESOURCE, NodeFilterConstraintType.PROPERTIES))
+ .thenReturn(Optional.of(ciNodeFilterDataDefinition));
final Response response = target()
.path(path)
.request(MediaType.APPLICATION_JSON)
@@ -337,7 +338,7 @@ public class ComponentNodeFilterServletTest extends JerseyTest {
verify(componentNodeFilterBusinessLogic, times(1))
.updateNodeFilter(anyString(), anyString(), anyList(), anyBoolean(),
- ArgumentMatchers.any(ComponentTypeEnum.class));
+ ArgumentMatchers.any(ComponentTypeEnum.class), ArgumentMatchers.any(NodeFilterConstraintType.class));
assertThat(response.getStatus()).isEqualTo(HttpStatus.OK_200);
}
@@ -359,7 +360,7 @@ public class ComponentNodeFilterServletTest extends JerseyTest {
when(componentNodeFilterBusinessLogic
.updateNodeFilter(componentId, componentInstance, Collections.singletonList(constraint),
- true, ComponentTypeEnum.RESOURCE))
+ true, ComponentTypeEnum.RESOURCE, NodeFilterConstraintType.PROPERTIES))
.thenReturn(Optional.empty());
final Response response = target()
.path(path)
@@ -369,7 +370,7 @@ public class ComponentNodeFilterServletTest extends JerseyTest {
verify(componentNodeFilterBusinessLogic, times(1))
.updateNodeFilter(anyString(), anyString(), anyList(), anyBoolean(),
- ArgumentMatchers.any(ComponentTypeEnum.class));
+ ArgumentMatchers.any(ComponentTypeEnum.class), ArgumentMatchers.any(NodeFilterConstraintType.class));
assertThat(response.getStatus()).isEqualTo(HttpStatus.INTERNAL_SERVER_ERROR_500);