diff options
Diffstat (limited to 'src/test/java')
-rw-r--r-- | src/test/java/org/openecomp/sdc/impl/SdcToscaParserBasicTest.java | 5 | ||||
-rw-r--r-- | src/test/java/org/openecomp/sdc/impl/ToscaParserNodeTemplateTest.java | 9 |
2 files changed, 12 insertions, 2 deletions
diff --git a/src/test/java/org/openecomp/sdc/impl/SdcToscaParserBasicTest.java b/src/test/java/org/openecomp/sdc/impl/SdcToscaParserBasicTest.java index a73f121..90124c5 100644 --- a/src/test/java/org/openecomp/sdc/impl/SdcToscaParserBasicTest.java +++ b/src/test/java/org/openecomp/sdc/impl/SdcToscaParserBasicTest.java @@ -33,8 +33,10 @@ public abstract class SdcToscaParserBasicTest { static ISdcCsarHelper resolveGetInputCsarFalse; static ISdcCsarHelper resolveGetInputCsarQA; static ISdcCsarHelper resolveReqsCapsCsarQA; + static ISdcCsarHelper portMirroring; - static Map<String, HashMap<String, List<String>>> fdntCsarHelper_Data; + + static Map<String, HashMap<String, List<String>>> fdntCsarHelper_Data; @BeforeClass public static void init() throws SdcToscaParserException, JToscaException, IOException { @@ -53,6 +55,7 @@ public abstract class SdcToscaParserBasicTest { resolveGetInputCsarQA = getCsarHelper("csars/service-resolve-get-input-csar_QA.csar"); QAServiceForToscaParserTests = getCsarHelper("csars/service-ServiceForToscaParserTests-csar.csar"); resolveReqsCapsCsarQA = getCsarHelper("csars/service-sunny-flow2.csar"); + portMirroring = getCsarHelper("csars/service-PortMirroring.csar"); fdntCsarHelper_Data = new HashMap<String, HashMap<String, List<String>>>(){ { diff --git a/src/test/java/org/openecomp/sdc/impl/ToscaParserNodeTemplateTest.java b/src/test/java/org/openecomp/sdc/impl/ToscaParserNodeTemplateTest.java index 2c62ca2..ad240b1 100644 --- a/src/test/java/org/openecomp/sdc/impl/ToscaParserNodeTemplateTest.java +++ b/src/test/java/org/openecomp/sdc/impl/ToscaParserNodeTemplateTest.java @@ -483,11 +483,18 @@ public class ToscaParserNodeTemplateTest extends SdcToscaParserBasicTest { public void testServiceNodeTemplateBySdcType() { List<NodeTemplate> serviceVfList = fdntCsarHelper.getServiceNodeTemplateBySdcType(SdcTypes.VF); assertNotNull(serviceVfList); - assertEquals(2, serviceVfList.size()); + assertEquals(serviceVfList.size(), 2); assertEquals(serviceVfList.get(0).getName(), "FDNT 1"); } @Test + public void testServiceNodeTemplateBySdcTypeServiceProxy() { + List<NodeTemplate> serviceProxies = portMirroring.getServiceNodeTemplateBySdcType(SdcTypes.SERVICE_PROXY); + assertNotNull(serviceProxies); + assertEquals(serviceProxies.size(), 2); + } + + @Test public void testServiceNodeTemplateByNullSdcType() { List<NodeTemplate> serviceVfList = fdntCsarHelper.getServiceNodeTemplateBySdcType(null); assertNotNull(serviceVfList); |