Allow a longer timeout on stopping background job

This commit is contained in:
dsyer
2010-01-12 17:34:21 +00:00
parent 953fb3a5b4
commit 3053f49605

View File

@@ -48,6 +48,10 @@ public class SplitInterruptedJobParserTests extends AbstractJobParserTests {
Thread.sleep(100L);
jobExecution.setStatus(BatchStatus.STOPPING);
Thread.sleep(200L);
int count = 0;
while(jobExecution.getStatus()==BatchStatus.STOPPING && count++<10) {
Thread.sleep(200L);
}
assertEquals(BatchStatus.STOPPED, jobExecution.getStatus());
assertEquals(ExitStatus.STOPPED.getExitCode(), jobExecution.getExitStatus().getExitCode());