HBASE-21258 Add resetting of flags for RS Group pre/post hooks in TestRSGroups

This commit is contained in:
tedyu 2018-10-01 15:07:06 -07:00
parent f9d51b67e4
commit 4d7235ec54
1 changed files with 26 additions and 1 deletions

View File

@ -133,7 +133,7 @@ public class TestRSGroups extends TestRSGroupsBase {
INIT = true;
afterMethod();
}
observer.resetFlags();
}
@After
@ -305,6 +305,31 @@ public class TestRSGroups extends TestRSGroupsBase {
boolean preGetRSGroupInfoOfServerCalled = false;
boolean postGetRSGroupInfoOfServerCalled = false;
void resetFlags() {
preBalanceRSGroupCalled = false;
postBalanceRSGroupCalled = false;
preMoveServersCalled = false;
postMoveServersCalled = false;
preMoveTablesCalled = false;
postMoveTablesCalled = false;
preAddRSGroupCalled = false;
postAddRSGroupCalled = false;
preRemoveRSGroupCalled = false;
postRemoveRSGroupCalled = false;
preRemoveServersCalled = false;
postRemoveServersCalled = false;
preMoveServersAndTables = false;
postMoveServersAndTables = false;
preGetRSGroupInfoCalled = false;
postGetRSGroupInfoCalled = false;
preGetRSGroupInfoOfTableCalled = false;
postGetRSGroupInfoOfTableCalled = false;
preListRSGroupsCalled = false;
postListRSGroupsCalled = false;
preGetRSGroupInfoOfServerCalled = false;
postGetRSGroupInfoOfServerCalled = false;
}
@Override
public Optional<MasterObserver> getMasterObserver() {
return Optional.of(this);