Updated the repo to support JDK 17
[holmes/common.git] / holmes-actions / src / test / java / org / onap / holmes / common / aai / AaiQuery4CcvpnTest.java
index 55e7b6b..0df99b5 100644 (file)
@@ -1,5 +1,5 @@
 /**
- * Copyright 2018-2021 ZTE Corporation.
+ * Copyright 2018-2023 ZTE Corporation.
  * <p>
  * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
  * in compliance with the License. You may obtain a copy of the License at
@@ -25,6 +25,7 @@ import org.onap.holmes.common.exception.CorrelationException;
 import org.onap.holmes.common.utils.JerseyClient;
 import org.powermock.api.easymock.PowerMock;
 import org.powermock.core.classloader.annotations.PrepareForTest;
+import org.powermock.core.classloader.annotations.SuppressStaticInitializationFor;
 import org.powermock.modules.junit4.PowerMockRunner;
 import org.powermock.reflect.Whitebox;
 
@@ -36,11 +37,10 @@ import static org.easymock.EasyMock.anyObject;
 import static org.easymock.EasyMock.anyString;
 import static org.hamcrest.CoreMatchers.equalTo;
 import static org.junit.Assert.assertThat;
-import static org.onap.holmes.common.config.MicroServiceConfig.MSB_ADDR;
-
 
 @RunWith(PowerMockRunner.class)
 @PrepareForTest(JerseyClient.class)
+@SuppressStaticInitializationFor("org.onap.holmes.common.utils.JerseyClient")
 public class AaiQuery4CcvpnTest {
 
     @Rule
@@ -56,8 +56,6 @@ public class AaiQuery4CcvpnTest {
 
     @BeforeClass
     static public void beforeClass() {
-        System.setProperty(MSB_ADDR, "127.0.0.1:80");
-
         File file = new File(AaiQuery4CcvpnTest.class.getClassLoader().getResource("./ccvpn.data.json").getFile());
         BufferedReader reader = null;
         try {