aboutsummaryrefslogtreecommitdiffstats
path: root/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test
diff options
context:
space:
mode:
authorDivesh Mirchandani <Divesh.Mirchandani@amdocs.com>2017-09-14 19:14:21 +0530
committerDivesh Mirchandani <Divesh.Mirchandani@amdocs.com>2017-09-18 17:26:38 +0530
commit396cb378ab8940b1adb8ba1adc656d0b4ad66f99 (patch)
treeb4f6ddc8e7cdfe39bfcbdc75cff7e85c284c5b65 /openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test
parent27f5c2b105676eebb477714fd7323467151965d2 (diff)
Fixed SONAR issues
Fixed blocker, critical, major & minor SONAR issues. Issue-ID: SDC-343 Change-Id: I72e5a3a7fa7d7407a92f98f77e4334827f70f926 Signed-off-by: dd4616 <Divesh.Mirchandani@amdocs.com>
Diffstat (limited to 'openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test')
-rw-r--r--openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java9
-rw-r--r--openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/informationArtifact/impl/TxtInformationArtifactGeneratorImplTest.java13
2 files changed, 11 insertions, 11 deletions
diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java
index fe42f6ccd3..39c14e64fd 100644
--- a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java
+++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/dao/ServiceModelDaoFactoryTest.java
@@ -122,12 +122,15 @@ public class ServiceModelDaoFactoryTest {
Assert.assertTrue(model instanceof ToscaServiceModel);
if (model instanceof ToscaServiceModel) {
- artifact001 =
- (String) ((ToscaServiceModel) model).getArtifactFiles().getFileList().toArray()[0];
+ setArtifact((ToscaServiceModel) model);
}
}
-
+ private static void setArtifact(ToscaServiceModel model)
+ {
+ artifact001 =
+ (String) (model).getArtifactFiles().getFileList().toArray()[0];
+ }
private ToscaServiceModel getToscaServiceModel() {
Map<String, ServiceTemplate> serviceTemplates = getServiceTemplates(baseServiceTemplateName);
diff --git a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/informationArtifact/impl/TxtInformationArtifactGeneratorImplTest.java b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/informationArtifact/impl/TxtInformationArtifactGeneratorImplTest.java
index ab36e8e5a1..9f2f733a64 100644
--- a/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/informationArtifact/impl/TxtInformationArtifactGeneratorImplTest.java
+++ b/openecomp-be/lib/openecomp-sdc-vendor-software-product-lib/openecomp-sdc-vendor-software-product-core/src/test/java/org/openecomp/sdc/vendorsoftwareproduct/informationArtifact/impl/TxtInformationArtifactGeneratorImplTest.java
@@ -21,6 +21,11 @@
package org.openecomp.sdc.vendorsoftwareproduct.informationArtifact.impl;
+import static org.mockito.Matchers.anyObject;
+import static org.mockito.Matchers.anyString;
+import static org.openecomp.sdc.vendorsoftwareproduct.informationArtifact.impl.TxtInformationArtifactConstants.HEADER;
+import static org.openecomp.sdc.vendorsoftwareproduct.informationArtifact.impl.TxtInformationArtifactConstants.VFC_COMPUTE_CPU_OVER_SUBSCRIPTION;
+
import org.junit.Assert;
import org.mockito.InjectMocks;
import org.mockito.Mock;
@@ -36,8 +41,6 @@ import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.com
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.general.Hypervisor;
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.general.Recovery;
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.network.NetworkCapacity;
-import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.storage.Backup;
-import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.component.storage.Storage;
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.nic.IpConfiguration;
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.nic.Network;
import org.openecomp.sdc.vendorsoftwareproduct.types.questionnaire.nic.NicQuestionnaire;
@@ -50,16 +53,10 @@ import org.openecomp.sdc.versioning.dao.types.Version;
import org.testng.annotations.BeforeMethod;
import org.testng.annotations.Test;
-import javax.annotation.processing.SupportedAnnotationTypes;
import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
-import static org.mockito.Matchers.anyObject;
-import static org.mockito.Matchers.anyString;
-import static org.openecomp.sdc.vendorsoftwareproduct.informationArtifact.impl.TxtInformationArtifactConstants.HEADER;
-import static org.openecomp.sdc.vendorsoftwareproduct.informationArtifact.impl.TxtInformationArtifactConstants.VFC_COMPUTE_CPU_OVER_SUBSCRIPTION;
-
public class TxtInformationArtifactGeneratorImplTest {
private static final String NETWORK_DESC = "\"network desc\"";