From e6bb4897ed95432312771147af5e7c815c6f896f Mon Sep 17 00:00:00 2001 From: tkellner Date: Wed, 15 Jan 2014 14:00:53 +0000 Subject: Change Test HTTP Server port git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@1293 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4 --- .../src/test/java/at/gv/egiz/bku/binding/DataUrlConnectionTest.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'bkucommon') diff --git a/bkucommon/src/test/java/at/gv/egiz/bku/binding/DataUrlConnectionTest.java b/bkucommon/src/test/java/at/gv/egiz/bku/binding/DataUrlConnectionTest.java index f74c75c7..83acaefa 100644 --- a/bkucommon/src/test/java/at/gv/egiz/bku/binding/DataUrlConnectionTest.java +++ b/bkucommon/src/test/java/at/gv/egiz/bku/binding/DataUrlConnectionTest.java @@ -67,6 +67,8 @@ public class DataUrlConnectionTest extends AbstractBindingProcessorTest { private final Logger log = LoggerFactory.getLogger(DataUrlConnectionTest.class); + private static final int PORT = 8082; + static HttpServer server; static HTTPBindingProcessorImpl bindingProcessor; @@ -76,7 +78,7 @@ public class DataUrlConnectionTest extends AbstractBindingProcessorTest { public static void setUpHTTPServer() throws IOException { Logger log = LoggerFactory.getLogger(DataUrlConnectionTest.class); log.debug("setting up HTTPServer"); - InetSocketAddress addr = new InetSocketAddress("localhost", 8081); + InetSocketAddress addr = new InetSocketAddress("localhost", PORT); server = HttpServer.create(addr, 0); server.createContext("/", new DataUrlHandler()); server.start(); @@ -118,7 +120,7 @@ public class DataUrlConnectionTest extends AbstractBindingProcessorTest { // @Test public void openConnectionTest() throws Exception { - URL dataUrl = new URL("http://localhost:8081/"); + URL dataUrl = new URL("http://localhost:" + PORT + "/"); log.debug("creating DataUrlConnection " + dataUrl.toString()); DataUrlConnectionImpl c = new DataUrlConnectionImpl(dataUrl); -- cgit v1.2.3