Increased sleep intervals to avoid a race.

This commit is contained in:
akwizgran
2011-10-21 20:42:09 +01:00
parent ef61eaa804
commit 1173e0a563

View File

@@ -45,12 +45,12 @@ public class SimpleSocketPluginTest extends TestCase {
Socket s = new Socket();
assertEquals(0, callback.incomingConnections);
s.connect(addr, 100);
Thread.sleep(10);
Thread.sleep(100);
assertEquals(1, callback.incomingConnections);
s.close();
// Stop the plugin
plugin.stop();
Thread.sleep(10);
Thread.sleep(100);
// The plugin should no longer be listening
try {
s = new Socket();