提交 1e75a63f 编写于 作者: K Kohsuke Kawaguchi

Maybe this test is flaky because it doesn't wait for

jenkins.udpBroadcastThread to become ready?
上级 bce9417d
......@@ -32,9 +32,14 @@ public class UDPBroadcastThreadTest extends HudsonTestCase {
* Multicast based clients should be able to receive multiple replies.
*/
public void testMulticast() throws Exception {
UDPBroadcastThread second = new UDPBroadcastThread(hudson);
UDPBroadcastThread second = new UDPBroadcastThread(jenkins);
second.start();
UDPBroadcastThread third = new UDPBroadcastThread(jenkins);
third.start();
second.ready.block();
third.ready.block();
try {
DatagramSocket s = new DatagramSocket();
......@@ -45,6 +50,7 @@ public class UDPBroadcastThreadTest extends HudsonTestCase {
receiveAndVerify(s);
receiveAndVerify(s);
} finally {
third.interrupt();
second.interrupt();
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册