add sample to show how to use waitForJobsToFinish in Junit 4 test cases