From e7b02c6027fec763ce1793abb0983ecfcee7f6e1 Mon Sep 17 00:00:00 2001 From: Eylon Malin Date: Sun, 1 Sep 2019 14:39:35 +0300 Subject: Fix "old-csars" test: csarWithVnfWithVfModuleInModel Issue-ID: VID-378 Change-Id: Icde5058772379f2d48477c05c986f4fe8a30f446 Signed-off-by: Eylon Malin Signed-off-by: Ittay Stern --- .../onap/vid/asdc/parser/ToscaParserImpl2Test.java | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'vid-app-common/src/test/java/org/onap') diff --git a/vid-app-common/src/test/java/org/onap/vid/asdc/parser/ToscaParserImpl2Test.java b/vid-app-common/src/test/java/org/onap/vid/asdc/parser/ToscaParserImpl2Test.java index e25834bd6..aeb010071 100644 --- a/vid-app-common/src/test/java/org/onap/vid/asdc/parser/ToscaParserImpl2Test.java +++ b/vid-app-common/src/test/java/org/onap/vid/asdc/parser/ToscaParserImpl2Test.java @@ -32,7 +32,6 @@ import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; import static org.onap.vid.asdc.parser.ToscaParserImpl2.Constants.ECOMP_GENERATED_NAMING_PROPERTY; import static org.onap.vid.testUtils.TestUtils.assertJsonStringEqualsIgnoreNulls; -import static org.onap.vid.testUtils.TestUtils.testWithSystemProperty; import com.fasterxml.jackson.core.JsonProcessingException; import com.fasterxml.jackson.databind.ObjectMapper; @@ -286,15 +285,15 @@ public class ToscaParserImpl2Test { @Test(dataProvider = "oldCsarUuid") public void csarWithVnfWithVfModuleInModel(String oldCsarUuid, String vnfName) throws Exception { - testWithSystemProperty("asdc.model.namespace", "com.att.d2.", ()-> { - ToscaParser tosca = new ToscaParserImpl(); - final UUID uuid = UUID.fromString(oldCsarUuid); - final ServiceModel serviceModel = tosca.makeServiceModel(oldCsarUuid, asdcClient.getServiceToscaModel(uuid), asdcClient.getService(uuid)); - assertThat(serviceModel.getVnfs(), aMapWithSize(1)); - assertThat(serviceModel.getVfModules(), aMapWithSize(2)); - assertThat(serviceModel.getVolumeGroups(), aMapWithSize(0)); - assertThat(serviceModel.getVnfs().get(vnfName).getVfModules(), aMapWithSize(2)); - }); + ToscaParser tosca = new ToscaParserImpl(); + final UUID uuid = UUID.fromString(oldCsarUuid); + final ServiceModel serviceModel = tosca.makeServiceModel( + oldCsarUuid, asdcClient.getServiceToscaModel(uuid), asdcClient.getService(uuid) + ); + assertThat(serviceModel.getVnfs(), aMapWithSize(1)); + assertThat(serviceModel.getVfModules(), aMapWithSize(2)); + assertThat(serviceModel.getVolumeGroups(), aMapWithSize(0)); + assertThat(serviceModel.getVnfs().get(vnfName).getVfModules(), aMapWithSize(2)); } @Test -- cgit 1.2.3-korg