Making SerializedSuspendableExecutionContext use AbstractNodeQueue instead of ConcurrentLinkedQueue

This commit is contained in:
Viktor Klang 2013-03-28 20:14:37 +01:00
parent fb2decbcda
commit 3ab3de1eb6
161 changed files with 3553 additions and 1656 deletions

View file

@ -187,6 +187,24 @@ public class TestKitDocTest {
}};
//#test-awaitCond
}
@Test
public void demonstrateAwaitAssert() {
//#test-awaitAssert
new JavaTestKit(system) {{
getRef().tell(42, null);
new AwaitAssert(
duration("1 second"), // maximum wait time
duration("100 millis") // interval at which to check the condition
) {
// do not put code outside this method, will run afterwards
protected void check() {
assertEquals(msgAvailable(), true);
}
};
}};
//#test-awaitAssert
}
@Test
@SuppressWarnings("unchecked") // due to generic varargs