@Test public void testConvertWhenStackNetworkNotNullAndStackNetworkAttributesAreNotNullThenExpectedMapShouldBeSavedInNetworkParams() { String subnetCIDR = "testSubnetCIDR"; Json attributes = mock(Json.class); Map<String, Object> params = new LinkedHashMap<>(); when(stack.getNetwork()).thenReturn(stackNetwork); when(stackNetwork.getSubnetCIDR()).thenReturn(subnetCIDR); when(stackNetwork.getAttributes()).thenReturn(attributes); when(attributes.getMap()).thenReturn(params); CloudStack result = underTest.convert(stack); assertNotNull(result.getNetwork()); assertEquals(subnetCIDR, result.getNetwork().getSubnet().getCidr()); assertEquals(params, result.getNetwork().getParameters()); }
public CloudStack convert(Stack stack) { return convert(stack, Collections.emptySet()); }
StackToCloudStackConverter { public CloudStack convert(Stack stack) { return convert(stack, Collections.emptySet()); } }
StackToCloudStackConverter { public CloudStack convert(Stack stack) { return convert(stack, Collections.emptySet()); }  }
StackToCloudStackConverter { public CloudStack convert(Stack stack) { return convert(stack, Collections.emptySet()); }  CloudStack convert(Stack stack); CloudStack convertForDownscale(Stack stack, Set<String> deleteRequestedInstances); CloudStack convertForTermination(Stack stack, String instanceId); CloudStack convert(Stack stack, Collection<String> deleteRequestedInstances); List<CloudInstance> buildInstances(Stack stack); CloudInstance buildInstance(InstanceMetaData instanceMetaData, InstanceGroup instanceGroup,
            StackAuthentication stackAuthentication, Long privateId, InstanceStatus status); Map<String, Object> buildCloudInstanceParameters(String environmentCrn, InstanceMetaData instanceMetaData, CloudPlatform platform); }
StackToCloudStackConverter { public CloudStack convert(Stack stack) { return convert(stack, Collections.emptySet()); }  CloudStack convert(Stack stack); CloudStack convertForDownscale(Stack stack, Set<String> deleteRequestedInstances); CloudStack convertForTermination(Stack stack, String instanceId); CloudStack convert(Stack stack, Collection<String> deleteRequestedInstances); List<CloudInstance> buildInstances(Stack stack); CloudInstance buildInstance(InstanceMetaData instanceMetaData, InstanceGroup instanceGroup,
            StackAuthentication stackAuthentication, Long privateId, InstanceStatus status); Map<String, Object> buildCloudInstanceParameters(String environmentCrn, InstanceMetaData instanceMetaData, CloudPlatform platform);  }