lock map needs more time to update

This commit is contained in:
Aidan Hahn 2019-05-26 22:26:11 -07:00
parent 84ad967a98
commit e7059a36c6
No known key found for this signature in database
GPG key ID: 327711E983899316

View file

@ -207,16 +207,13 @@ public class ProcessManagerTest {
int status = this.manager.getProcessStatus(this.asyncTestPid);
assertEquals(4, status); // should time out after 2 secs
// cancel the blocking thread, release lock
//future.cancel(true);
// try to grab unrelated lock (not nessesary, but important it works)
int statusTertiary = this.manager.getProcessStatus(secondProcess);
assertNotEquals(4, statusTertiary);
// give lockMap small time to update
try {
Thread.sleep(100);
Thread.sleep(200);
} catch (InterruptedException e) {
System.err.println("[!!] Thread for async test interrupted!");
}