From 171f79518d1944314fee39c1270ef347753a43d0 Mon Sep 17 00:00:00 2001 From: Emmanuel Bigeon Date: Sat, 27 Oct 2018 14:02:21 -0400 Subject: [PATCH] Made port public constant Signed-off-by: Emmanuel Bigeon --- .../src/test/java/net/bigeon/gclc/socket/TestServer.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gclc-socket/src/test/java/net/bigeon/gclc/socket/TestServer.java b/gclc-socket/src/test/java/net/bigeon/gclc/socket/TestServer.java index 802a213..5b7c769 100644 --- a/gclc-socket/src/test/java/net/bigeon/gclc/socket/TestServer.java +++ b/gclc-socket/src/test/java/net/bigeon/gclc/socket/TestServer.java @@ -46,6 +46,7 @@ import net.bigeon.gclc.ConsoleApplication; @SuppressWarnings({ "javadoc", "nls" }) public class TestServer { + public static final int PORT = 3300; private static SocketConsoleApplicationShell SHELL; private static ConnexionManager manager; @@ -75,7 +76,7 @@ public class TestServer { input.setPrompt("> \n"); output = new PluggableConsoleOutput(); manager = new DConnexionManager<>(); - SHELL = new SocketConsoleApplicationShell(3300, + SHELL = new SocketConsoleApplicationShell(PORT, InetAddress.getByName("127.0.0.1")); final ConsoleApplication app = ConsoleTestApplication.create(output, input, manager); @@ -91,13 +92,13 @@ public class TestServer { }); th.start(); try { - Object waiting = new Object(); + final Object waiting = new Object(); synchronized (waiting) { while (!input.isPrompting()) { waiting.wait(50); } } - } catch (InterruptedException e) { + } catch (final InterruptedException e) { Thread.currentThread().interrupt(); } }