This is an automated email from the ASF dual-hosted git repository.
reta pushed a commit to branch 3.4.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
The following commit(s) were added to refs/heads/3.4.x-fixes by this push:
new 82a4e41 Fixing post-merge issues
82a4e41 is described below
commit 82a4e41011b3dc843395c33b02e0f8855e988667
Author: Andriy Redko <[email protected]>
AuthorDate: Mon Feb 14 18:39:32 2022 -0500
Fixing post-merge issues
---
.../SwaggerUiConfigurationQueryConfigTest.java | 25 ++++++++++++++--------
1 file changed, 16 insertions(+), 9 deletions(-)
diff --git
a/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/description/SwaggerUiConfigurationQueryConfigTest.java
b/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/description/SwaggerUiConfigurationQueryConfigTest.java
index 3e64231..57039d2 100644
---
a/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/description/SwaggerUiConfigurationQueryConfigTest.java
+++
b/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/description/SwaggerUiConfigurationQueryConfigTest.java
@@ -25,15 +25,14 @@ import javax.ws.rs.core.Response;
import com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider;
-import org.apache.cxf.Bus;
import org.apache.cxf.jaxrs.JAXRSServerFactoryBean;
import org.apache.cxf.jaxrs.client.WebClient;
import org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider;
import org.apache.cxf.jaxrs.model.AbstractResourceInfo;
import org.apache.cxf.jaxrs.swagger.Swagger2Feature;
import org.apache.cxf.jaxrs.swagger.ui.SwaggerUiConfig;
-import org.apache.cxf.testutil.common.AbstractClientServerTestBase;
-import org.apache.cxf.testutil.common.AbstractServerTestServerBase;
+import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
+import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
import org.junit.BeforeClass;
import org.junit.Test;
@@ -43,13 +42,13 @@ import static org.hamcrest.CoreMatchers.equalTo;
import static org.hamcrest.MatcherAssert.assertThat;
import static org.junit.Assert.assertTrue;
-public class SwaggerUiConfigurationQueryConfigTest extends
AbstractClientServerTestBase {
+public class SwaggerUiConfigurationQueryConfigTest extends
AbstractBusClientServerTestBase {
private static final String PORT =
allocatePort(SwaggerUiConfigurationQueryConfigTest.class);
- public static class Server extends AbstractServerTestServerBase {
+ public static class Server extends AbstractBusTestServerBase {
@Override
- protected org.apache.cxf.endpoint.Server createServer(Bus bus) throws
Exception {
+ protected void run() {
final JAXRSServerFactoryBean sf = new JAXRSServerFactoryBean();
sf.setResourceClasses(BookStoreSwagger2.class);
sf.setResourceProvider(BookStoreSwagger2.class,
@@ -60,11 +59,19 @@ public class SwaggerUiConfigurationQueryConfigTest extends
AbstractClientServerT
feature.setSwaggerUiConfig(new
SwaggerUiConfig().url("/swagger.json").queryConfigEnabled(true));
sf.setFeatures(Arrays.asList(feature));
sf.setAddress("http://localhost:" + PORT + "/");
- return sf.create();
+ sf.create();
}
- public static void main(String[] args) throws Exception {
- new Server().start();
+ public static void main(String[] args) {
+ try {
+ Server s = new Server();
+ s.start();
+ } catch (Exception ex) {
+ ex.printStackTrace();
+ System.exit(-1);
+ } finally {
+ System.out.println("done!");
+ }
}
}