aboutsummaryrefslogtreecommitdiffstats
path: root/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest
diff options
context:
space:
mode:
authorvasraz <vasyl.razinkov@est.tech>2022-01-10 19:23:57 +0000
committerMichael Morris <michael.morris@est.tech>2022-01-13 09:38:58 +0000
commit0fbe309f797b4cdac9d507a6f3dfd193644aa224 (patch)
tree8c276b59e5a03dab17714ff3b50d96432bf45fb3 /openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest
parent9253465137072c13a7720bac1496b2f3c8655eb8 (diff)
Improve testing stability
Signed-off-by: Vasyl Razinkov <vasyl.razinkov@est.tech> Change-Id: I3f631642a97e65d6628816767e0a5408f02f4bc6 Issue-ID: SDC-3839
Diffstat (limited to 'openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest')
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentDependenciesImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentMonitoringUploadsImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComputeImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/DeploymentFlavorsImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ImagesImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImplTest.java4
-rw-r--r--openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NicsImplTest.java4
9 files changed, 18 insertions, 18 deletions
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentDependenciesImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentDependenciesImplTest.java
index fe90ed2528..1bc1e33eab 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentDependenciesImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentDependenciesImplTest.java
@@ -43,7 +43,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class ComponentDependenciesImplTest {
@@ -66,7 +66,7 @@ public class ComponentDependenciesImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
ComponentDependencyModelEntity e = new ComponentDependencyModelEntity();
e.setSourceComponentId("sourceid");
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentImplTest.java
index ab64bfca11..85429065c1 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentImplTest.java
@@ -47,7 +47,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class ComponentImplTest {
@@ -67,7 +67,7 @@ public class ComponentImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
ComponentEntity ce = new ComponentEntity();
ce.setId(vspId);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentMonitoringUploadsImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentMonitoringUploadsImplTest.java
index 119a5dbe53..28dc1cbb85 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentMonitoringUploadsImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentMonitoringUploadsImplTest.java
@@ -41,7 +41,7 @@ import javax.ws.rs.core.Response;
import java.io.ByteArrayInputStream;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class ComponentMonitoringUploadsImplTest {
@@ -64,7 +64,7 @@ public class ComponentMonitoringUploadsImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
MonitoringUploadStatus result = new MonitoringUploadStatus();
result.setSnmpPoll("p");
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImplTest.java
index 48011ea740..6320a38720 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComponentProcessesImplTest.java
@@ -47,7 +47,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
import static org.mockito.Mockito.mock;
@@ -75,7 +75,7 @@ public class ComponentProcessesImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
ProcessEntity pe = new ProcessEntity();
pe.setId(vspId);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComputeImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComputeImplTest.java
index 7cd78e0c1d..8195ae0a5e 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComputeImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ComputeImplTest.java
@@ -48,7 +48,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class ComputeImplTest {
@@ -72,7 +72,7 @@ public class ComputeImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
ListComputeResponse lcr = new ListComputeResponse();
lcr.setAssociatedWithDeploymentFlavor(false);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/DeploymentFlavorsImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/DeploymentFlavorsImplTest.java
index 008ef8134f..4b0710a277 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/DeploymentFlavorsImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/DeploymentFlavorsImplTest.java
@@ -44,7 +44,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class DeploymentFlavorsImplTest {
@@ -64,7 +64,7 @@ public class DeploymentFlavorsImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
DeploymentFlavorEntity e = new DeploymentFlavorEntity();
e.setId(deploymentFlavorId);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ImagesImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ImagesImplTest.java
index 349ab9b401..e7dc2843a7 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ImagesImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/ImagesImplTest.java
@@ -49,7 +49,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class ImagesImplTest {
@@ -79,7 +79,7 @@ public class ImagesImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
ImageEntity ie = new ImageEntity();
ie.setComponentId(componentId);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImplTest.java
index 756e8fdde3..0fcb19d5d4 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NetworksImplTest.java
@@ -21,7 +21,7 @@
package org.openecomp.sdcrests.vsp.rest.services;
import static org.mockito.Mockito.when;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import java.util.Collection;
import java.util.Collections;
@@ -57,7 +57,7 @@ public class NetworksImplTest {
@Before
public void setUp() {
- initMocks(this);
+ openMocks(this);
NetworkEntity e = new NetworkEntity();
e.setId(networkId);
diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NicsImplTest.java b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NicsImplTest.java
index a6a4e98f82..4f0a5d3cdd 100644
--- a/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NicsImplTest.java
+++ b/openecomp-be/api/openecomp-sdc-rest-webapp/vendor-software-products-rest/vendor-software-products-rest-services/src/test/java/org/openecomp/sdcrests/vsp/rest/services/NicsImplTest.java
@@ -47,7 +47,7 @@ import java.util.Collection;
import java.util.Collections;
import java.util.UUID;
-import static org.mockito.MockitoAnnotations.initMocks;
+import static org.mockito.MockitoAnnotations.openMocks;
import static org.mockito.Mockito.when;
public class NicsImplTest {
@@ -71,7 +71,7 @@ public class NicsImplTest {
@Before
public void setUp() {
try {
- initMocks(this);
+ openMocks(this);
NicEntity e = new NicEntity();
e.setComponentId(componentId);