Increase test failure timer.
- Was failing under heavy laod.
Change-Id: I30bd6e8c00d42fe585420583186a98fbf1f7ff5d
diff --git a/utils/misc/src/test/java/org/onlab/util/BlockingBooleanTest.java b/utils/misc/src/test/java/org/onlab/util/BlockingBooleanTest.java
index 7624923..0a8899c 100644
--- a/utils/misc/src/test/java/org/onlab/util/BlockingBooleanTest.java
+++ b/utils/misc/src/test/java/org/onlab/util/BlockingBooleanTest.java
@@ -31,7 +31,7 @@
*/
public class BlockingBooleanTest {
- private static final int TIMEOUT = 100; //ms
+ private static final int FAIL_TIMEOUT = 1000; //ms
@Test
public void basics() {
@@ -62,7 +62,7 @@
}
b.set(value);
try {
- assertTrue(latch.await(TIMEOUT, TimeUnit.MILLISECONDS));
+ assertTrue(latch.await(FAIL_TIMEOUT, TimeUnit.MILLISECONDS));
} catch (InterruptedException e) {
fail();
}
@@ -94,7 +94,7 @@
}
});
try {
- assertTrue(latch.await(TIMEOUT, TimeUnit.MILLISECONDS));
+ assertTrue(latch.await(FAIL_TIMEOUT, TimeUnit.MILLISECONDS));
} catch (InterruptedException e) {
fail();
}
@@ -126,14 +126,14 @@
});
}
try {
- assertTrue(sameLatch.await(TIMEOUT, TimeUnit.MILLISECONDS));
+ assertTrue(sameLatch.await(FAIL_TIMEOUT, TimeUnit.MILLISECONDS));
assertEquals(waitLatch.getCount(), numThreads / 2);
} catch (InterruptedException e) {
fail();
}
b.set(true);
try {
- assertTrue(waitLatch.await(TIMEOUT, TimeUnit.MILLISECONDS));
+ assertTrue(waitLatch.await(FAIL_TIMEOUT, TimeUnit.MILLISECONDS));
} catch (InterruptedException e) {
fail();
}
@@ -158,7 +158,7 @@
}
});
try {
- assertTrue(latch.await(TIMEOUT, TimeUnit.MILLISECONDS));
+ assertTrue(latch.await(FAIL_TIMEOUT, TimeUnit.MILLISECONDS));
} catch (InterruptedException e) {
fail();
}