diff options
Diffstat (limited to 'catalog-be/src/test/java')
58 files changed, 58 insertions, 58 deletions
diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/PropertyBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/PropertyBusinessLogicTest.java index 63bb0b8828..e6457c9de7 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/PropertyBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/PropertyBusinessLogicTest.java @@ -120,7 +120,7 @@ public class PropertyBusinessLogicTest extends BaseBusinessLogicMock { @Before public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); ExternalConfiguration.setAppName("catalog-be"); // User data and management diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/ServiceDistributionBLTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/ServiceDistributionBLTest.java index 9b6a26d5e3..72cb51676b 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/ServiceDistributionBLTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/ServiceDistributionBLTest.java @@ -87,7 +87,7 @@ class ServiceDistributionBLTest extends ComponentBusinessLogicMock { public void setup() { ExternalConfiguration.setAppName("catalog-be"); - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); final ComponentsUtils componentsUtils = new ComponentsUtils(Mockito.mock(AuditingManager.class)); bl.setComponentsUtils(componentsUtils); serviceToActivate = new Service(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/DistributionEngineTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/DistributionEngineTest.java index 8473bb2cb7..94245c76d7 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/DistributionEngineTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/DistributionEngineTest.java @@ -82,7 +82,7 @@ public class DistributionEngineTest{ @Before public void setUpMock() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); distributionEngineConfigurationMock = new DummyDistributionConfigurationManager(); envs = getEnvs(ENV_ID); modifier.setUserId(USER_ID); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/EnvironmentsEngineTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/EnvironmentsEngineTest.java index 109743436f..357010e888 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/EnvironmentsEngineTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/EnvironmentsEngineTest.java @@ -76,7 +76,7 @@ public class EnvironmentsEngineTest { @Before public void preStart() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); new ConfigurationManager(new FSConfigurationSource(ExternalConfiguration.getChangeListener(), "src/test/resources/config/catalog-be")); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/ServiceDistributionArtifactsBuilderTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/ServiceDistributionArtifactsBuilderTest.java index c1cd5f3181..46fcbddd2d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/ServiceDistributionArtifactsBuilderTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/ServiceDistributionArtifactsBuilderTest.java @@ -62,7 +62,7 @@ public class ServiceDistributionArtifactsBuilderTest extends BeConfDependentTest @Before public void setUpMock() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/StepsTenantIsolation.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/StepsTenantIsolation.java index 77c332a314..40e76d3205 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/StepsTenantIsolation.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/distribution/engine/StepsTenantIsolation.java @@ -90,7 +90,7 @@ public class StepsTenantIsolation { @Before public void beforeScenario() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); when(operationalEnvironmentDao.getByEnvironmentsStatus(EnvironmentStatusEnum.COMPLETED)) .thenReturn(Either.right(CassandraOperationStatus.NOT_FOUND)); doNothing().when(envEngine).createUebTopicsForEnvironments(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ArtifactsBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ArtifactsBusinessLogicTest.java index 14d00efd42..0734bc5ec6 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ArtifactsBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ArtifactsBusinessLogicTest.java @@ -215,7 +215,7 @@ public class ArtifactsBusinessLogicTest extends BaseBusinessLogicMock { @Before public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); Either<ArtifactDefinition, StorageOperationStatus> NotFoundResult = Either .right(StorageOperationStatus.NOT_FOUND); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilitiesBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilitiesBusinessLogicTest.java index 9bbe64f3f8..e70f3a7144 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilitiesBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilitiesBusinessLogicTest.java @@ -92,7 +92,7 @@ public class CapabilitiesBusinessLogicTest extends BaseBusinessLogicMock { @Before public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); ExternalConfiguration.setAppName("catalog-be"); ComponentsUtils componentsUtils = new ComponentsUtils(Mockito.mock(AuditingManager.class)); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilityTypeImportManagerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilityTypeImportManagerTest.java index a4d02e146c..10ca58d64d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilityTypeImportManagerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CapabilityTypeImportManagerTest.java @@ -80,7 +80,7 @@ public class CapabilityTypeImportManagerTest { @Before public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CategoriesImportManagerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CategoriesImportManagerTest.java index a42f2ef650..f7d0709307 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CategoriesImportManagerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/CategoriesImportManagerTest.java @@ -80,7 +80,7 @@ public class CategoriesImportManagerTest { @Before public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentInterfaceOperationBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentInterfaceOperationBusinessLogicTest.java index 93334d19dc..6018207cb7 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentInterfaceOperationBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentInterfaceOperationBusinessLogicTest.java @@ -88,7 +88,7 @@ public class ComponentInterfaceOperationBusinessLogicTest extends BaseBusinessLo @BeforeEach public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); componentInterfaceOperationBusinessLogic = new ComponentInterfaceOperationBusinessLogic(elementDao, groupOperation, groupInstanceOperation, groupTypeOperation, interfaceOperation, interfaceLifecycleTypeOperation, artifactToscaOperation, diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentLockerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentLockerTest.java index d2c7c7a640..74d0e61252 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentLockerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentLockerTest.java @@ -46,7 +46,7 @@ public class ComponentLockerTest { @Before
public void init() {
- MockitoAnnotations.initMocks(this);
+ MockitoAnnotations.openMocks(this);
}
@Test
diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java index cd708599f5..ed5c5b9a2d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentNodeFilterBusinessLogicTest.java @@ -124,7 +124,7 @@ public class ComponentNodeFilterBusinessLogicTest extends BaseBusinessLogicMock @BeforeEach public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); componentNodeFilterBusinessLogic = new ComponentNodeFilterBusinessLogic(elementDao, groupOperation, groupInstanceOperation, groupTypeOperation, interfaceOperation, interfaceLifecycleTypeOperation, artifactToscaOperation, diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentSubstitutionFilterBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentSubstitutionFilterBusinessLogicTest.java index ffda5ecd80..7435a8b6e2 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentSubstitutionFilterBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ComponentSubstitutionFilterBusinessLogicTest.java @@ -102,7 +102,7 @@ public class ComponentSubstitutionFilterBusinessLogicTest extends BaseBusinessLo @BeforeEach public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); componentSubstitutionFilterBusinessLogic = new ComponentSubstitutionFilterBusinessLogic(elementDao, groupOperation, groupInstanceOperation, groupTypeOperation, interfaceOperation, interfaceLifecycleTypeOperation, artifactToscaOperation, diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ConsumerBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ConsumerBusinessLogicTest.java index 6239d3302c..886747eea9 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ConsumerBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ConsumerBusinessLogicTest.java @@ -80,7 +80,7 @@ class ConsumerBusinessLogicTest extends BaseBusinessLogicMock { interfaceOperation, interfaceLifecycleTypeOperation, artifactToscaOperation); consumerDataDefinition = new ConsumerDataDefinition(); consumer = new ConsumerDefinition(); - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); user = new User("Stan", "Lee", "stan.lee", "stan.lee@marvel.com", "ADMIN", 1542024000L); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DataTypeBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DataTypeBusinessLogicTest.java index c870d3b7f2..3719b9b850 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DataTypeBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DataTypeBusinessLogicTest.java @@ -87,7 +87,7 @@ public class DataTypeBusinessLogicTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); testInstance.setToscaOperationFacade(toscaOperationFacadeMock); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DistributionMonitoringBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DistributionMonitoringBusinessLogicTest.java index 0d6e87a165..7b111ba52f 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DistributionMonitoringBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/DistributionMonitoringBusinessLogicTest.java @@ -67,7 +67,7 @@ public class DistributionMonitoringBusinessLogicTest extends BaseBusinessLogicMo @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); businessLogic = new DistributionMonitoringBusinessLogic(elementDao, groupOperation, groupInstanceOperation, groupTypeOperation, interfaceOperation, interfaceLifecycleTypeOperation, cassandraDao, artifactToscaOperation); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InputsBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InputsBusinessLogicTest.java index 9700a86f7e..bd3e9ae633 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InputsBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InputsBusinessLogicTest.java @@ -149,7 +149,7 @@ public class InputsBusinessLogicTest { @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); service = new Service(); service.setUniqueId(COMPONENT_ID); service.setLastUpdaterUserId(USER_ID); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InterfaceLifecycleTypeImportManagerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InterfaceLifecycleTypeImportManagerTest.java index 9aa68d81cd..93a861daa8 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InterfaceLifecycleTypeImportManagerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/InterfaceLifecycleTypeImportManagerTest.java @@ -80,7 +80,7 @@ public class InterfaceLifecycleTypeImportManagerTest { @Before public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/OutputsBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/OutputsBusinessLogicTest.java index 88d98de279..9c7e3848c6 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/OutputsBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/OutputsBusinessLogicTest.java @@ -127,7 +127,7 @@ class OutputsBusinessLogicTest { @BeforeEach public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); service = new Service(); service.setUniqueId(COMPONENT_ID); service.setLastUpdaterUserId(USER_ID); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/PolicyBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/PolicyBusinessLogicTest.java index 8ee13e8e59..7a8a15a905 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/PolicyBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/PolicyBusinessLogicTest.java @@ -143,7 +143,7 @@ public class PolicyBusinessLogicTest { @Before public void initBl() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); businessLogic.setComponentsUtils(componentsUtils); businessLogic.setToscaOperationFacade(toscaOperationFacade); businessLogic.setJanusGraphDao(janusGraphDao); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ProductBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ProductBusinessLogicTest.java index 42d4e4b2ad..fd8aede325 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ProductBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ProductBusinessLogicTest.java @@ -106,7 +106,7 @@ public class ProductBusinessLogicTest extends ComponentBusinessLogicMock { artifactsBusinessLogic, componentInstanceBusinessLogic, artifactToscaOperation, componentContactIdValidator, componentNameValidator, componentTagsValidator, componentValidator, componentIconValidator, componentProjectCodeValidator, componentDescriptionValidator ); - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); product = new Product(); user = new User(); contacts = new ArrayList<>(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/RequirementBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/RequirementBusinessLogicTest.java index 671715e721..63a9d3cbe0 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/RequirementBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/RequirementBusinessLogicTest.java @@ -89,7 +89,7 @@ public class RequirementBusinessLogicTest extends BaseBusinessLogicMock { @Before public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); ExternalConfiguration.setAppName("catalog-be"); ComponentsUtils componentsUtils = new ComponentsUtils(Mockito.mock(AuditingManager.class)); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceBusinessLogicTest.java index 334bffd342..0018ed003d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceBusinessLogicTest.java @@ -261,7 +261,7 @@ public class ResourceBusinessLogicTest { @Before public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); Mockito.reset(propertyOperation); // Elements diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceInstanceBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceInstanceBusinessLogicTest.java index f69a9dc76d..b5037179cf 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceInstanceBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ResourceInstanceBusinessLogicTest.java @@ -100,7 +100,7 @@ public class ResourceInstanceBusinessLogicTest extends BaseBusinessLogicMock { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); Map<String, Object> deploymentResourceArtifacts = ConfigurationManager.getConfigurationManager().getConfiguration().getDeploymentResourceInstanceArtifacts(); Map<String, Object> placeHolderData = (Map<String, Object>) deploymentResourceArtifacts.get(ArtifactsBusinessLogic.HEAT_ENV_NAME); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportBusinessLogicTest.java index 822fad5f5f..884978a77f 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportBusinessLogicTest.java @@ -136,7 +136,7 @@ class ServiceImportBusinessLogicTest extends ServiceImportBussinessLogicBaseTest @BeforeEach public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); when(artifactDefinition.getMandatory()).thenReturn(true); when(artifactDefinition.getArtifactName()).thenReturn("creatorFullName"); when(artifactDefinition.getArtifactType()).thenReturn("TOSCA_CSAR"); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportParseLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportParseLogicTest.java index 6d9467dd80..368b3886dd 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportParseLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/impl/ServiceImportParseLogicTest.java @@ -137,7 +137,7 @@ class ServiceImportParseLogicTest extends ServiceImportBussinessLogicBaseTestSet @BeforeEach public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); // Elements mockElementDao = new ElementOperationMock(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/GlobalInputsFilteringBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/GlobalInputsFilteringBusinessLogicTest.java index 3c2c1c3020..458d104026 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/GlobalInputsFilteringBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/GlobalInputsFilteringBusinessLogicTest.java @@ -64,7 +64,7 @@ public class GlobalInputsFilteringBusinessLogicTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/TopologyComparatorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/TopologyComparatorTest.java index 7f77b7de53..9e8cff56c2 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/TopologyComparatorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/TopologyComparatorTest.java @@ -57,7 +57,7 @@ public class TopologyComparatorTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentCapabilitiesPropertiesMergeBLTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentCapabilitiesPropertiesMergeBLTest.java index 2b48f1e981..473f6fb155 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentCapabilitiesPropertiesMergeBLTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentCapabilitiesPropertiesMergeBLTest.java @@ -65,7 +65,7 @@ public class ComponentCapabilitiesPropertiesMergeBLTest { @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceArtifactsMergeTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceArtifactsMergeTest.java index 66c535e0ce..d29621addc 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceArtifactsMergeTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceArtifactsMergeTest.java @@ -61,7 +61,7 @@ public class ComponentInstanceArtifactsMergeTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceHeatEnvMergeTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceHeatEnvMergeTest.java index a23508f797..1be72f5f67 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceHeatEnvMergeTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceHeatEnvMergeTest.java @@ -69,7 +69,7 @@ public class ComponentInstanceHeatEnvMergeTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceInterfacesMergeTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceInterfacesMergeTest.java index 33590e82ff..5c19dcbc34 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceInterfacesMergeTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceInterfacesMergeTest.java @@ -76,7 +76,7 @@ public class ComponentInstanceInterfacesMergeTest { @Before public void setUpData() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); user = new User(); user.setUserId("44"); user.setRole(UserRoleEnum.ADMIN.getName()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceMergeDataBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceMergeDataBusinessLogicTest.java index bbd2467106..5f0f6afecc 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceMergeDataBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstanceMergeDataBusinessLogicTest.java @@ -73,7 +73,7 @@ public class ComponentInstanceMergeDataBusinessLogicTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); testInstance.setComponentInstancesMergeBLs(Arrays.asList(componentInstanceMergeInterfaceMock1, componentInstanceMergeInterfaceMock2)); new ConfigurationManager(new FSConfigurationSource(ExternalConfiguration.getChangeListener(), "src/test/resources/config/catalog-be")); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstancePropsAndInputsMergeTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstancePropsAndInputsMergeTest.java index eedd44df19..e12010c750 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstancePropsAndInputsMergeTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/instance/ComponentInstancePropsAndInputsMergeTest.java @@ -87,7 +87,7 @@ class ComponentInstancePropsAndInputsMergeTest { @BeforeEach public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); resourceToUpdate = new ResourceBuilder().addInstanceInput(INSTANCE_ID1, "instInput1") .addInstanceInput(INSTANCE_ID1, "instInput2") .addInstanceProperty(INSTANCE_ID1, "instProp1") diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/path/ComponentInstanceForwardingPathMergeTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/path/ComponentInstanceForwardingPathMergeTest.java index 50eaea9ad2..322a2bf9f0 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/path/ComponentInstanceForwardingPathMergeTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/path/ComponentInstanceForwardingPathMergeTest.java @@ -57,7 +57,7 @@ public class ComponentInstanceForwardingPathMergeTest extends BaseForwardingPath @BeforeEach public void setUpData() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); user = new User(); user.setUserId("44"); user.setRole(UserRoleEnum.ADMIN.getName()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstanceInputsMergeBLTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstanceInputsMergeBLTest.java index 429b2d7320..9b8752fef2 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstanceInputsMergeBLTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstanceInputsMergeBLTest.java @@ -66,7 +66,7 @@ public class ComponentInstanceInputsMergeBLTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); ComponentInstance instance1 = new ComponentInstanceBuilder().setId(INSTANCE1).setName(INSTANCE1).build(); ComponentInstance instance2 = new ComponentInstanceBuilder().setId(INSTANCE2).setName(INSTANCE2).build(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstancePropertiesMergeBLTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstancePropertiesMergeBLTest.java index 77cb7613e9..818b225418 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstancePropertiesMergeBLTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/ComponentInstancePropertiesMergeBLTest.java @@ -69,7 +69,7 @@ public class ComponentInstancePropertiesMergeBLTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); oldResource = new ResourceBuilder() .addComponentInstance(INSTANCE1, OLD_INSTANCE1) .addComponentInstance(INSTANCE2, OLD_INSTANCE2) diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/DataDefinitionsValuesMergingBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/DataDefinitionsValuesMergingBusinessLogicTest.java index bf3ab33378..aa7f606a94 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/DataDefinitionsValuesMergingBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/merge/property/DataDefinitionsValuesMergingBusinessLogicTest.java @@ -49,7 +49,7 @@ public class DataDefinitionsValuesMergingBusinessLogicTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/path/ForwardingPathValidatorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/path/ForwardingPathValidatorTest.java index ae44ceac90..eef8c80b3c 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/path/ForwardingPathValidatorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/path/ForwardingPathValidatorTest.java @@ -60,7 +60,7 @@ public class ForwardingPathValidatorTest implements ForwardingPathTestUtils { @BeforeEach public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); mock = Mockito.mock(ResponseFormatManager.class); when(toscaOperationFacade.getToscaElement(any(), any(ComponentParametersView.class))).thenReturn(Either.left(service)); when(mock.getResponseFormat(any())).thenReturn(new ResponseFormat()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/ComponentInstanceInputPropertyDeceleratorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/ComponentInstanceInputPropertyDeceleratorTest.java index 538e4652f6..82e32c304b 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/ComponentInstanceInputPropertyDeceleratorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/ComponentInstanceInputPropertyDeceleratorTest.java @@ -56,7 +56,7 @@ public class ComponentInstanceInputPropertyDeceleratorTest { @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeclarationOrchestratorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeclarationOrchestratorTest.java index d6bd322dcc..5f242d8198 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeclarationOrchestratorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeclarationOrchestratorTest.java @@ -86,7 +86,7 @@ public class PropertyDeclarationOrchestratorTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); service = new ServiceBuilder().setUniqueId(SERVICE_UID).build(); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeserializationOrchestratorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeserializationOrchestratorTest.java index d1cf303c0b..37fce9bb0d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeserializationOrchestratorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/PropertyDeserializationOrchestratorTest.java @@ -59,7 +59,7 @@ public class PropertyDeserializationOrchestratorTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Test(expected = IllegalStateException.class) diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/propertytopolicydeclarators/ComponentInstancePropertyToPolicyDeclaratorTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/propertytopolicydeclarators/ComponentInstancePropertyToPolicyDeclaratorTest.java index 5de4c48245..7a7f20bfc9 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/propertytopolicydeclarators/ComponentInstancePropertyToPolicyDeclaratorTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/property/propertytopolicydeclarators/ComponentInstancePropertyToPolicyDeclaratorTest.java @@ -74,7 +74,7 @@ public class ComponentInstancePropertyToPolicyDeclaratorTest { @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); service = new Service(); componentInstance = new ComponentInstance(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/scheduledtasks/RecoveryThreadManagerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/scheduledtasks/RecoveryThreadManagerTest.java index 0d1c839a08..13d847164d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/scheduledtasks/RecoveryThreadManagerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/scheduledtasks/RecoveryThreadManagerTest.java @@ -60,7 +60,7 @@ public class RecoveryThreadManagerTest extends BeConfDependentTest { @Before public void initMocks() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); reset(operationalEnvironmentDao, environmentsEngine, scheduledService); recoveryThreadManager.init(); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/upgrade/UpgradeBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/upgrade/UpgradeBusinessLogicTest.java index 7b4e8d90d6..7b1a7e986f 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/upgrade/UpgradeBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/upgrade/UpgradeBusinessLogicTest.java @@ -114,7 +114,7 @@ public class UpgradeBusinessLogicTest { @Before public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); upgradeBusinessLogic = new UpgradeBusinessLogic(lifecycleBusinessLogic, componentInstanceBusinessLogic, userValidations, toscaOperationFacade, componentsUtils, upgradeOperation, diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/CapabilitiesValidationTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/CapabilitiesValidationTest.java index 672a383a79..e6274cdf6d 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/CapabilitiesValidationTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/CapabilitiesValidationTest.java @@ -44,7 +44,7 @@ public class CapabilitiesValidationTest { private final CapabilitiesValidationUtilTest capabilitiesValidationUtilTest = new CapabilitiesValidationUtilTest(); @Before public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); responseFormatManagerMock = Mockito.mock(ResponseFormatManager.class); when(responseFormatManagerMock.getResponseFormat(any())).thenReturn(new ResponseFormat()); when(responseFormatManagerMock.getResponseFormat(any(), any())).thenReturn(new ResponseFormat()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ComponentValidationsTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ComponentValidationsTest.java index bbdbcdf713..829b0b907f 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ComponentValidationsTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ComponentValidationsTest.java @@ -58,7 +58,7 @@ class ComponentValidationsTest { @BeforeEach public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); new ConfigurationManager(new FSConfigurationSource(ExternalConfiguration.getChangeListener(), "src/test/resources/config/catalog-be")); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/InterfaceOperationValidationTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/InterfaceOperationValidationTest.java index 2f132abfae..bfcfd59d07 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/InterfaceOperationValidationTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/InterfaceOperationValidationTest.java @@ -72,7 +72,7 @@ public class InterfaceOperationValidationTest { @Before public void setup() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); responseFormatManagerMock = Mockito.mock(ResponseFormatManager.class); when(responseFormatManagerMock.getResponseFormat(any())).thenReturn(new ResponseFormat()); when(responseFormatManagerMock.getResponseFormat(any(), any())).thenReturn(new ResponseFormat()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/NodeFilterValidationTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/NodeFilterValidationTest.java index 3a15959cc8..3bdd22c6fc 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/NodeFilterValidationTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/NodeFilterValidationTest.java @@ -72,7 +72,7 @@ public class NodeFilterValidationTest { @BeforeEach public void setup() { componentsUtils = Mockito.mock(ComponentsUtils.class); - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); new ConfigurationManager(new FSConfigurationSource(ExternalConfiguration.getChangeListener(), "src/test/resources/config/catalog-be")); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/RequirementValidationTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/RequirementValidationTest.java index 309490ae9c..16ca6acdb3 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/RequirementValidationTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/RequirementValidationTest.java @@ -42,7 +42,7 @@ public class RequirementValidationTest { private final RequirementValidationUtilTest requirementValidationUtilTest = new RequirementValidationUtilTest(); @Before public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); responseFormatManagerMock = Mockito.mock(ResponseFormatManager.class); when(responseFormatManagerMock.getResponseFormat(any())).thenReturn(new ResponseFormat()); when(responseFormatManagerMock.getResponseFormat(any(), any())).thenReturn(new ResponseFormat()); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ServiceDistributionValidationTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ServiceDistributionValidationTest.java index 483becc474..44e35fca06 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ServiceDistributionValidationTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/ServiceDistributionValidationTest.java @@ -87,7 +87,7 @@ public class ServiceDistributionValidationTest { @Before public void setUp() throws Exception { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); user = new User(); user.setUserId(USER_ID); errResponse = new ResponseFormat(); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/UserValidationsTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/UserValidationsTest.java index 6c08fcb357..c19cf4679e 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/UserValidationsTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/components/validation/UserValidationsTest.java @@ -53,7 +53,7 @@ public class UserValidationsTest { @BeforeEach public void setUp() { //TestUtilsSdc.setFinalStatic(UserValidations.class, "log", LoggerFactory.getLogger(UserValidations.class)); - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); new ConfigurationManager(new FSConfigurationSource(ExternalConfiguration.getChangeListener(), "src/test/resources/config/catalog-be")); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/distribution/DistributionBusinessLogicTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/distribution/DistributionBusinessLogicTest.java index 997ea2fb4f..523f58f03e 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/distribution/DistributionBusinessLogicTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/distribution/DistributionBusinessLogicTest.java @@ -67,7 +67,7 @@ public class DistributionBusinessLogicTest extends BeConfDependentTest { @Before public void init() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); Mockito.reset(cambriaHandler); } diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/filters/GatewayFilterTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/filters/GatewayFilterTest.java index 08d36913ac..56b2d46746 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/filters/GatewayFilterTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/filters/GatewayFilterTest.java @@ -93,7 +93,7 @@ public class GatewayFilterTest { @Before public void initMocks(){ - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Before diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/filters/ReqValidationFilterTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/filters/ReqValidationFilterTest.java index 8656560b7a..06843e6b3b 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/filters/ReqValidationFilterTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/filters/ReqValidationFilterTest.java @@ -73,7 +73,7 @@ public class ReqValidationFilterTest { @Before public void initMocks(){ - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); } @Before diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/impl/aaf/RoleAuthorizationHandlerTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/impl/aaf/RoleAuthorizationHandlerTest.java index c83cd3d25c..d9f249a42a 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/impl/aaf/RoleAuthorizationHandlerTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/impl/aaf/RoleAuthorizationHandlerTest.java @@ -65,7 +65,7 @@ class RoleAuthorizationHandlerTest { @BeforeEach public void setUp() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); when(joinPoint.getSignature()).thenReturn(signature); when(signature.toShortString()).thenReturn("methodName"); when(joinPoint.getThis()).thenReturn(beGenericServlet); diff --git a/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java b/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java index fac1586a8b..548a046229 100644 --- a/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java +++ b/catalog-be/src/test/java/org/openecomp/sdc/be/servlets/ComponentNodeFilterServletTest.java @@ -147,7 +147,7 @@ class ComponentNodeFilterServletTest extends JerseyTest { @BeforeAll public void initClass() { - MockitoAnnotations.initMocks(this); + MockitoAnnotations.openMocks(this); when(request.getSession()).thenReturn(session); when(session.getServletContext()).thenReturn(servletContext); when(servletContext.getAttribute(Constants.WEB_APPLICATION_CONTEXT_WRAPPER_ATTR)).thenReturn(webAppContextWrapper); |