This commit is contained in:
Jacky 2017-12-19 21:00:03 -05:00
parent eeb8ade5c0
commit cce3ab6240

View File

@ -141,15 +141,19 @@ public class UrlFetchingTests extends RefineTest {
Process process = op.createProcess(project, options); Process process = op.createProcess(project, options);
process.startPerforming(pm); process.startPerforming(pm);
Assert.assertTrue(process.isRunning()); Assert.assertTrue(process.isRunning());
try { for(int i = 0;i < 12;i++) {
// We have 100 rows and 500 ms per row but only two distinct try {
// values so we should not wait more than ~2000 ms to get the // We have 100 rows and 500 ms per row but only two distinct
// results. Just to make sure the test passes with plenty of // values so we should not wait more than ~2000 ms to get the
// net latency we sleep for longer (but still less than // results. Just to make sure the test passes with plenty of
// 50,000ms). // net latency we sleep for longer (but still less than
Thread.sleep(5000); // 50,000ms).
} catch (InterruptedException e) { Thread.sleep(5000);
Assert.fail("Test interrupted"); if (process.isDone())
break;
} catch (InterruptedException e) {
Assert.fail("Test interrupted");
}
} }
Assert.assertFalse(process.isRunning()); Assert.assertFalse(process.isRunning());