Better test cases with waitFor().