aboutsummaryrefslogtreecommitdiffstats
path: root/bpmn/MSOCommonBPMN/src/test
diff options
context:
space:
mode:
authorSmokowski, Steven <steve.smokowski@att.com>2020-02-03 14:48:24 -0500
committerBenjamin, Max (mb388a) <mb388a@att.com>2020-02-03 14:48:26 -0500
commitb58f841d09e1d832ea4aeae1334f151a98a1f4c8 (patch)
treed18b6906ed5b2c4ccf5a5876d33907d82b85774e /bpmn/MSOCommonBPMN/src/test
parente9c0b88ed9b0e9a538ee87f25f3ea4c99f853702 (diff)
modifications to create network to add lob
Add platform and line of business to network Update to split out network Issue-ID: SO-2637 Signed-off-by: Benjamin, Max (mb388a) <mb388a@att.com> Change-Id: I5cbc3bc77986b6d4d420d2158df46924fcd74c0b
Diffstat (limited to 'bpmn/MSOCommonBPMN/src/test')
-rw-r--r--bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java21
1 files changed, 18 insertions, 3 deletions
diff --git a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
index a45e803cf0..1acf4edb4a 100644
--- a/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
+++ b/bpmn/MSOCommonBPMN/src/test/java/org/onap/so/bpmn/servicedecomposition/tasks/BBInputSetupTest.java
@@ -1262,7 +1262,7 @@ public class BBInputSetupTest {
verify(SPY_bbInputSetup, times(1)).mapCatalogNetwork(network, modelInfo, service);
instanceName = "networkName2";
- L3Network network2 = SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, resourceId, null);
+ L3Network network2 = SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, resourceId, null, parameter);
SPY_bbInputSetup.populateL3Network(parameter);
verify(SPY_bbInputSetup, times(2)).mapCatalogNetwork(network2, modelInfo, service);
}
@@ -2832,17 +2832,32 @@ public class BBInputSetupTest {
expected.setNetworkId(networkId);
expected.setNetworkName(instanceName);
expected.setCloudParams(cloudParams);
+ Platform platform = new Platform();
+ platform.setPlatformName("platformName");
+ expected.setPlatform(platform);
+ LineOfBusiness lineOfBusiness = new LineOfBusiness();
+ lineOfBusiness.setLineOfBusinessName("lineOfBusiness");
+ expected.setLineOfBusiness(lineOfBusiness);
expected.setOrchestrationStatus(OrchestrationStatus.PRECREATED);
Map<ResourceKey, String> lookupKeyMap = new HashMap<>();
List<Map<String, String>> instanceParams = new ArrayList<>();
instanceParams.add(cloudParams);
- L3Network actual = SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, networkId, instanceParams);
+ org.onap.so.serviceinstancebeans.Platform platformRequest = new org.onap.so.serviceinstancebeans.Platform();
+ org.onap.so.serviceinstancebeans.LineOfBusiness lineOfBusinessRequest =
+ new org.onap.so.serviceinstancebeans.LineOfBusiness();
+ lineOfBusinessRequest.setLineOfBusinessName("lineOfBusiness");
+ platformRequest.setPlatformName("platformName");
+ BBInputSetupParameter parameter = new BBInputSetupParameter.Builder().setRequestId(REQUEST_ID)
+ .setPlatform(platformRequest).setLineOfBusiness(lineOfBusinessRequest).build();
+ L3Network actual =
+ SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, networkId, instanceParams, parameter);
assertThat(actual, sameBeanAs(expected));
assertEquals("LookupKeyMap is populated", networkId, lookupKeyMap.get(ResourceKey.NETWORK_ID));
expected.getCloudParams().clear();
- actual = SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, networkId, null);
+
+ actual = SPY_bbInputSetup.createNetwork(lookupKeyMap, instanceName, networkId, null, parameter);
assertThat(actual, sameBeanAs(expected));
}