summaryrefslogtreecommitdiffstats
path: root/bpmn/MSOInfrastructureBPMN/src/test
diff options
context:
space:
mode:
authorMarcus G K Williams <marcus.williams@intel.com>2018-03-14 15:07:31 -0700
committerMarcus Williams <marcus.williams@intel.com>2018-03-27 21:34:27 +0000
commitc4c512c8b0a46d92f7862b9f01a7969975937e06 (patch)
tree307ea34a7aab41f51a6e4434553c972555f41ff7 /bpmn/MSOInfrastructureBPMN/src/test
parentb4473da1a753e63e66f5a9a3b1984fd4736273c2 (diff)
Refactor homing flows for OOF/HPA
1. Split Homing into OOF and SNIRO versions 2. Added OOF API interactions 3. Added Unit tests for OOF Homing Code Issue-ID: SO-404 Change-Id: Ifeeeec9ea450d8b330110a565208ed89a1e18cde Signed-off-by: Marcus G K Williams <marcus.williams@intel.com>
Diffstat (limited to 'bpmn/MSOInfrastructureBPMN/src/test')
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/CreateVcpeResCustServiceTest.groovy3
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/DeleteVcpeResCustServiceTest.groovy2
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/resources/__files/DeleteVfModuleVolumeInfraV1/deleteVfModuleVolume_VID_request_st.json2
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/request.json6
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSIName.json6
-rw-r--r--bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSINameNoRollback.json8
6 files changed, 21 insertions, 6 deletions
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/CreateVcpeResCustServiceTest.groovy b/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/CreateVcpeResCustServiceTest.groovy
index 2c9d591399..a735121002 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/CreateVcpeResCustServiceTest.groovy
+++ b/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/CreateVcpeResCustServiceTest.groovy
@@ -32,6 +32,7 @@ import org.junit.Ignore
import org.mockito.MockitoAnnotations
import org.camunda.bpm.engine.delegate.BpmnError
import org.openecomp.mso.bpmn.core.WorkflowException
+import org.openecomp.mso.bpmn.core.domain.HomingSolution
import org.openecomp.mso.bpmn.mock.FileUtil
import static com.github.tomakehurst.wiremock.client.WireMock.aResponse
@@ -109,6 +110,7 @@ class CreateVcpeResCustServiceTest extends GroovyTestBase {
verify(mex).setVariable("brgWanMacAddress", "brgmac")
verify(mex).setVariable("customerLocation", ["customerLatitude":"32.897480", "customerLongitude":"-97.040443", "customerName":"some_company"])
+ verify(mex).setVariable("homingService", "sniro")
assertTrue(map.containsKey("serviceInputParams"))
assertTrue(map.containsKey(Prefix+"requestInfo"))
@@ -166,6 +168,7 @@ class CreateVcpeResCustServiceTest extends GroovyTestBase {
assertEquals("", map.get("brgWanMacAddress"))
assertEquals("", map.get("customerLocation"))
+ assertEquals("oof", map.get("homingService"))
assertTrue(map.containsKey("serviceInputParams"))
assertTrue(map.containsKey(Prefix+"requestInfo"))
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/DeleteVcpeResCustServiceTest.groovy b/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/DeleteVcpeResCustServiceTest.groovy
index fdc470f16d..b904a3f2d9 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/DeleteVcpeResCustServiceTest.groovy
+++ b/bpmn/MSOInfrastructureBPMN/src/test/groovy/org/openecomp/mso/bpmn/vcpe/scripts/DeleteVcpeResCustServiceTest.groovy
@@ -47,7 +47,7 @@ import org.openecomp.mso.bpmn.core.domain.ServiceDecomposition
import org.openecomp.mso.bpmn.core.domain.VnfResource
import org.openecomp.mso.bpmn.core.domain.AllottedResource
import org.openecomp.mso.bpmn.core.domain.ModelInfo
-import org.openecomp.mso.bpmn.core.domain.HomingSolution
+
import org.openecomp.mso.bpmn.core.RollbackData
import org.openecomp.mso.bpmn.vcpe.scripts.MapGetter
import org.openecomp.mso.bpmn.vcpe.scripts.MapSetter
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/DeleteVfModuleVolumeInfraV1/deleteVfModuleVolume_VID_request_st.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/DeleteVfModuleVolumeInfraV1/deleteVfModuleVolume_VID_request_st.json
index c6cc1ca428..52ead5f77f 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/DeleteVfModuleVolumeInfraV1/deleteVfModuleVolume_VID_request_st.json
+++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/DeleteVfModuleVolumeInfraV1/deleteVfModuleVolume_VID_request_st.json
@@ -7,7 +7,7 @@
"modelVersion": "1.0"
},
"cloudConfiguration": {
- "lcpCloudRegionId": "MDTWNJ21",
+ "lcpCloudRegionId": "cloudowner_MDTWNJ21",
"tenantId": "fba1bd1e195a404cacb9ce17a9b2b421"
},
"requestInfo": {
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/request.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/request.json
index 3e05ba0f9d..bc0a1ef491 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/request.json
+++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/request.json
@@ -23,7 +23,7 @@
},
"cloudConfiguration":
{
- "lcpCloudRegionId":"mdt1",
+ "lcpCloudRegionId":"cloudowner_mdt1",
"tenantId":"8b1df54faa3b49078e3416e21370a3ba"
},
"requestParameters":
@@ -43,6 +43,10 @@
"customerLongitude": "-97.040443",
"customerName": "some_company"
}
+ },
+ {
+ "name":"Homing_Solution",
+ "value":"sniro"
}
]
}
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSIName.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSIName.json
index cf02444705..4100ec76de 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSIName.json
+++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSIName.json
@@ -22,7 +22,7 @@
},
"cloudConfiguration":
{
- "lcpCloudRegionId":"mdt1",
+ "lcpCloudRegionId":"cloudowner_mdt1",
"tenantId":"8b1df54faa3b49078e3416e21370a3ba"
},
"requestParameters":
@@ -42,6 +42,10 @@
"customerLongitude": "-97.040443",
"customerName": "some_company"
}
+ },
+ {
+ "name":"Homing_Solution",
+ "value":"sniro"
}
]
}
diff --git a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSINameNoRollback.json b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSINameNoRollback.json
index 39be40aedd..5fc0b04180 100644
--- a/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSINameNoRollback.json
+++ b/bpmn/MSOInfrastructureBPMN/src/test/resources/__files/VCPE/CreateVcpeResCustService/requestNoSINameNoRollback.json
@@ -22,7 +22,7 @@
},
"cloudConfiguration":
{
- "lcpCloudRegionId":"mdt1",
+ "lcpCloudRegionId":"cloudowner_mdt1",
"tenantId":"8b1df54faa3b49078e3416e21370a3ba"
},
"requestParameters":
@@ -42,7 +42,11 @@
"customerLongitude": "-97.040443",
"customerName": "some_company"
}
- }
+ },
+ {
+ "name":"Homing_Solution",
+ "value":"sniro"
+ }
]
}
}