summaryrefslogtreecommitdiffstats
path: root/appc-outbound/appc-aai-client/provider/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'appc-outbound/appc-aai-client/provider/src/test')
-rw-r--r--appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/aai/TestAaiService.java6
-rw-r--r--appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/node/TestAAIResourceNode.java7
2 files changed, 10 insertions, 3 deletions
diff --git a/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/aai/TestAaiService.java b/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/aai/TestAaiService.java
index 717348584..a68e59af9 100644
--- a/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/aai/TestAaiService.java
+++ b/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/aai/TestAaiService.java
@@ -250,7 +250,7 @@ public class TestAaiService {
mockAai.populateAllVnfInfo1(ctx, "tmp.vnfInfo");
- mockAai.insertVnfcs(inParams, ctx, 2, 2);
+ mockAai.insertVnfcs(inParams, ctx, 2, 2,"vfModuleId1");
}
@@ -269,7 +269,7 @@ public class TestAaiService {
mockAai.populateAllVnfInfo1(ctx, "tmp.vnfInfo");
- mockAai.insertVnfcs(inParams, ctx, 2, 2);
+ mockAai.insertVnfcs(inParams, ctx, 2, 2, null);
assertEquals(ctx.getAttribute("tmp.vnfInfo.vm[0].vnfc-name"), "dbjx0001vm001dbj001");
assertEquals(ctx.getAttribute("tmp.vnfInfo.vm[0].vnfc-function-code"), "dbj");
@@ -296,7 +296,7 @@ public class TestAaiService {
mockAai.populateAllVnfInfo1(ctx, "tmp.vnfInfo");
- mockAai.insertVnfcs(inParams, ctx, 2, 2);
+ mockAai.insertVnfcs(inParams, ctx, 2, 2,null);
diff --git a/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/node/TestAAIResourceNode.java b/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/node/TestAAIResourceNode.java
index efb09e0be..e509a3403 100644
--- a/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/node/TestAAIResourceNode.java
+++ b/appc-outbound/appc-aai-client/provider/src/test/java/org/onap/appc/aai/client/node/TestAAIResourceNode.java
@@ -131,7 +131,14 @@ public class TestAAIResourceNode {
assertEquals(ctx.getAttribute("tmp.vnfInfo.vm[1].vnfc-type"), "vnfcType2");
assertEquals(ctx.getAttribute("tmp.vnfInfo.vm[1].vnfc-function-code"), "vnfcFuncCode2");
assertEquals(ctx.getAttribute("tmp.vnfInfo.vm[1].group-notation"), "vnfcGrpNot2");
+
+ ctx.setAttribute("tmp.vnfInfo.vm[0].vserver-id","ibcm0001id");
+ ctx.setAttribute("req-vf-module-id","vfModule1");
+ mrn.getAllVServersVnfcsInfo(inParams, ctx);
+ assertEquals(ctx.getAttribute("tmp.vnfInfo.vnf.vm-with-no-vnfcs-count-vf-module"),"1");
+ assertEquals(ctx.getAttribute("tmp.vnfInfo.vnf.vm-count-for-vf-module"),"1");
}
+
public void populateAllVServerInfo(SvcLogicContext ctx, String prefix) throws Exception {
ctx.setAttribute("vnf-id", "ibcx0001v");
ctx.setAttribute("vnf-host-ip-address", "000.00.00.00");