From 88c47a23b9428188ff5dd0b46941f8856465376b Mon Sep 17 00:00:00 2001 From: eeginux Date: Wed, 3 Apr 2019 14:28:09 +0000 Subject: PNF WF post instantiation configuration Add PNF ipv4/v6 address for config Deploy Add Integration test for CreateVcpeResCustService_simplified.bpmn Modify the PnfEventReadyDmaapClient to avoid one more running thread Refactor the so-bpmn-infrastructure-flows test resources Modify the CreateVcpeResCustService_simplified.bpmn Add ConfigurePnfResource.bpmn Add Delegates Issue-ID: SO-1506 Change-Id: Iffb69d1441ef0b485ee8cd3fb5da5f1a35279a95 Signed-off-by: eeginux --- .../onap/so/asdc/client/ASDCControllerITTest.java | 29 ++++++++++++++++++++++ 1 file changed, 29 insertions(+) (limited to 'asdc-controller/src/test/java') diff --git a/asdc-controller/src/test/java/org/onap/so/asdc/client/ASDCControllerITTest.java b/asdc-controller/src/test/java/org/onap/so/asdc/client/ASDCControllerITTest.java index 301ef14637..51559c2ffe 100644 --- a/asdc-controller/src/test/java/org/onap/so/asdc/client/ASDCControllerITTest.java +++ b/asdc-controller/src/test/java/org/onap/so/asdc/client/ASDCControllerITTest.java @@ -23,6 +23,7 @@ import static com.github.tomakehurst.wiremock.client.WireMock.ok; import static com.github.tomakehurst.wiremock.client.WireMock.post; import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNull; import static org.junit.Assert.fail; @@ -58,6 +59,8 @@ import org.onap.so.db.catalog.data.repository.ServiceRepository; import org.onap.so.db.catalog.data.repository.ToscaCsarRepository; import org.onap.so.db.catalog.data.repository.VnfCustomizationRepository; import org.onap.so.db.catalog.data.repository.VnfResourceRepository; +import org.onap.so.db.request.beans.WatchdogComponentDistributionStatus; +import org.onap.so.db.request.data.repository.WatchdogComponentDistributionStatusRepository; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; @@ -107,6 +110,9 @@ public class ASDCControllerITTest extends BaseTest { @Autowired private ServiceRepository serviceRepository; + @Autowired + protected WatchdogComponentDistributionStatusRepository watchdogCDStatusRepository; + private DistributionClientEmulator distributionClient; @Before @@ -263,6 +269,18 @@ public class ASDCControllerITTest extends BaseTest { assertEquals("PNF resource customization entity", 1, pnfCustList.size()); assertEquals(pnfCustomizationKey, pnfCustList.get(0).getModelCustomizationUUID()); + /** + * Check the watchdog for component distribution status + */ + List distributionList = watchdogCDStatusRepository + .findByDistributionId(this.distributionId); + assertNotNull(distributionList); + assertEquals(1, distributionList.size()); + WatchdogComponentDistributionStatus distributionStatus = distributionList.get(0); + assertEquals("COMPONENT_DONE_OK", distributionStatus.getComponentDistributionStatus()); + assertEquals("SO", distributionStatus.getComponentName()); + + } catch (Exception e) { logger.info(e.getMessage(), e); fail(e.getMessage()); @@ -411,6 +429,17 @@ public class ASDCControllerITTest extends BaseTest { List vnfCustList = service.getVnfCustomizations(); assertEquals("VNF resource customization entity", 1, vnfCustList.size()); assertEquals(vnfCustomizationKey, vnfCustList.get(0).getModelCustomizationUUID()); + + /** + * Check the watchdog for component distribution status + */ + List distributionList = watchdogCDStatusRepository + .findByDistributionId(this.distributionId); + assertNotNull(distributionList); + assertEquals(1, distributionList.size()); + WatchdogComponentDistributionStatus distributionStatus = distributionList.get(0); + assertEquals("COMPONENT_DONE_OK", distributionStatus.getComponentDistributionStatus()); + assertEquals("SO", distributionStatus.getComponentName()); } catch (Exception e) { logger.info(e.getMessage(), e); fail(e.getMessage()); -- cgit 1.2.3-korg