HBASE-24161 [flakey test] locking.TestEntityLocks.testEntityLockTimeout (#1477) (#1481)

Signed-off-by: stack <stack@apache.org>
This commit is contained in:
huaxiangsun 2020-04-10 09:40:50 -07:00 committed by GitHub
parent eae7523cef
commit 5e11ff100a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -175,7 +175,10 @@ public class TestEntityLocks {
assertTrue(lock.isLocked());
// Should get unlocked in next heartbeat i.e. after workerSleepTime. Wait 10x time to be sure.
assertTrue(waitLockTimeOut(lock, 10 * workerSleepTime));
assertFalse(lock.getWorker().isAlive());
// Works' run() returns, there is a small gap that the thread is still alive(os
// has not declare it is dead yet), so remove the following assertion.
// assertFalse(lock.getWorker().isAlive());
verify(abortable, times(1)).abort(any(), eq(null));
}