From c50fa7d7aea96f3cf09597b98663eb1d29196572 Mon Sep 17 00:00:00 2001 From: Valentin Spiroski Date: Fri, 9 Feb 2024 14:50:05 +0100 Subject: [PATCH] test_TestClientHandlerConstructor --- ...tructorTest.java => TestClientHandlerConstructor.java} | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) rename src/test/java/{ClientHandlerConstructorTest.java => TestClientHandlerConstructor.java} (66%) diff --git a/src/test/java/ClientHandlerConstructorTest.java b/src/test/java/TestClientHandlerConstructor.java similarity index 66% rename from src/test/java/ClientHandlerConstructorTest.java rename to src/test/java/TestClientHandlerConstructor.java index 7ebe7ce..0a20691 100644 --- a/src/test/java/ClientHandlerConstructorTest.java +++ b/src/test/java/TestClientHandlerConstructor.java @@ -3,7 +3,7 @@ import org.junit.Test; import java.io.*; import java.net.*; -public class ClientHandlerConstructorTest { +public class TestClientHandlerConstructor { @Test @@ -19,7 +19,11 @@ public class ClientHandlerConstructorTest { ClientHandler clientHandler = new ClientHandler(mockChatServer, mockSocket); - + try { + Thread.sleep(1000); // Adjust the sleep duration as needed + } catch (InterruptedException e) { + e.printStackTrace(); + } assertTrue(mockChatServer.getClients().contains(clientHandler));