Upgraded to Java 11
[holmes/common.git] / holmes-actions / src / test / java / org / onap / holmes / common / utils / MSBRegisterUtilTest.java
index 8eefd4e..e6b6f9d 100644 (file)
@@ -1,12 +1,12 @@
 /**\r
- * Copyright 2017 ZTE Corporation.\r
- *\r
+ * Copyright 2017-2020 ZTE Corporation.\r
+ * <p>\r
  * Licensed under the Apache License, Version 2.0 (the "License");\r
  * you may not use this file except in compliance with the License.\r
  * You may obtain a copy of the License at\r
- *\r
- *     http://www.apache.org/licenses/LICENSE-2.0\r
- *\r
+ * <p>\r
+ * http://www.apache.org/licenses/LICENSE-2.0\r
+ * <p>\r
  * Unless required by applicable law or agreed to in writing, software\r
  * distributed under the License is distributed on an "AS IS" BASIS,\r
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
 \r
 package org.onap.holmes.common.utils;\r
 \r
-import com.eclipsesource.jaxrs.consumer.ConsumerFactory;\r
-import javax.ws.rs.QueryParam;\r
-\r
 import org.easymock.EasyMock;\r
-import org.junit.Rule;\r
 import org.junit.Test;\r
 import org.junit.runner.RunWith;\r
-import org.onap.holmes.common.exception.CorrelationException;\r
-import org.onap.holmes.common.msb.MicroserviceBusRest;\r
-import org.onap.holmes.common.api.entity.ServiceRegisterEntity;\r
 import org.onap.holmes.common.config.MicroServiceConfig;\r
+import org.onap.holmes.common.exception.CorrelationException;\r
 import org.onap.msb.sdk.discovery.entity.MicroServiceFullInfo;\r
 import org.onap.msb.sdk.discovery.entity.MicroServiceInfo;\r
 import org.onap.msb.sdk.httpclient.msb.MSBServiceClient;\r
@@ -34,14 +28,12 @@ import org.powermock.api.easymock.PowerMock;
 import org.powermock.core.classloader.annotations.PowerMockIgnore;\r
 import org.powermock.core.classloader.annotations.PrepareForTest;\r
 import org.powermock.modules.junit4.PowerMockRunner;\r
-import org.powermock.modules.junit4.rule.PowerMockRule;\r
 \r
 @PrepareForTest({MicroServiceConfig.class, MSBServiceClient.class, MSBRegisterUtil.class})\r
 @PowerMockIgnore({"javax.ws.*"})\r
+@RunWith(PowerMockRunner.class)\r
 public class MSBRegisterUtilTest {\r
 \r
-    @Rule\r
-    public PowerMockRule powerMockRule = new PowerMockRule();\r
     private MSBRegisterUtil msbRegisterUtil = new MSBRegisterUtil();\r
 \r
     @Test\r