diff options
author | Benjamin, Max (mb388a) <mb388a@us.att.com> | 2018-09-09 10:27:05 -0400 |
---|---|---|
committer | Benjamin, Max (mb388a) <mb388a@us.att.com> | 2018-09-10 09:50:16 -0400 |
commit | 636dcb76e69ea9344750fc01b739ade57d20f7f6 (patch) | |
tree | 7c3443caf5a395a854151a211f08c97c59b71d12 /bpmn/so-bpmn-tasks/src/test | |
parent | df20b8670136d4c26c0ba28dde131ca8e0702546 (diff) |
updated create task BB
updated aai create task test to verify creation of obj
updated assignfabricconfig bpmn test with extra task
added junit test in aai config resources vfmod and vnfc
workflowaction passes more config id info to execute
updated assign config to connect objects in aai config
Change-Id: I19468f2bb83f4509e87d380a7c98a9f19358e1ef
Issue-ID: SO-1001
Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'bpmn/so-bpmn-tasks/src/test')
-rw-r--r-- | bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIConfigurationResourcesTest.java | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIConfigurationResourcesTest.java b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIConfigurationResourcesTest.java index 5948c66baa..3dc9a4da63 100644 --- a/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIConfigurationResourcesTest.java +++ b/bpmn/so-bpmn-tasks/src/test/java/org/onap/so/client/orchestration/AAIConfigurationResourcesTest.java @@ -43,6 +43,7 @@ import org.onap.so.bpmn.servicedecomposition.bbobjects.GenericVnf; import org.onap.so.bpmn.servicedecomposition.bbobjects.Pnf; import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceInstance; import org.onap.so.bpmn.servicedecomposition.bbobjects.ServiceProxy; +import org.onap.so.bpmn.servicedecomposition.bbobjects.VfModule; import org.onap.so.bpmn.servicedecomposition.bbobjects.VpnBinding; import org.onap.so.client.aai.AAIObjectType; import org.onap.so.client.aai.AAIResourcesClient; @@ -63,6 +64,7 @@ public class AAIConfigurationResourcesTest extends TestDataSetup{ private ServiceInstance serviceInstance; private GenericVnf genericVnf; private VpnBinding vpnBinding; + private VfModule vfModule; @Mock protected AAIResourcesClient MOCK_aaiResourcesClient; @@ -82,6 +84,7 @@ public class AAIConfigurationResourcesTest extends TestDataSetup{ serviceProxy = buildServiceProxy(); serviceInstance = buildServiceInstance(); genericVnf = buildGenericVnf(); + vfModule = buildVfModule(); vpnBinding = buildVpnBinding(); doReturn(MOCK_aaiResourcesClient).when(MOCK_injectionHelper).getAaiClient(); } @@ -126,6 +129,20 @@ public class AAIConfigurationResourcesTest extends TestDataSetup{ aaiConfigurationResources.connectConfigurationToGenericVnf(configuration.getConfigurationId(), genericVnf.getVnfId()); verify(MOCK_aaiResourcesClient, times(1)).connect(any(AAIResourceUri.class), any(AAIResourceUri.class)); } + + @Test + public void connectConfigurationToVfModuleTest() { + doNothing().when(MOCK_aaiResourcesClient).connect(isA(AAIResourceUri.class), isA(AAIResourceUri.class)); + aaiConfigurationResources.connectConfigurationToVfModule(configuration.getConfigurationId(), vfModule.getVfModuleId(),genericVnf.getVnfId()); + verify(MOCK_aaiResourcesClient, times(1)).connect(any(AAIResourceUri.class), any(AAIResourceUri.class)); + } + + @Test + public void connectConfigurationToVnfcTest() { + doNothing().when(MOCK_aaiResourcesClient).connect(isA(AAIResourceUri.class), isA(AAIResourceUri.class)); + aaiConfigurationResources.connectConfigurationToVnfc(configuration.getConfigurationId(), "vnfcName"); + verify(MOCK_aaiResourcesClient, times(1)).connect(any(AAIResourceUri.class), any(AAIResourceUri.class)); + } @Test public void connectConfigurationToVpnBindingTest() { |