HBASE-19556: Remove TestAssignmentManager#testGoodSplit, which no longer make sense

This commit is contained in:
Yi Liang 2017-12-19 11:31:44 -08:00 committed by Michael Stack
parent 32f6fd41c2
commit 70608acf28
No known key found for this signature in database
GPG Key ID: 9816C7FC8ACC93D2
1 changed files with 0 additions and 34 deletions

View File

@ -169,36 +169,6 @@ public class TestAssignmentManager {
if (this.am.waitServerReportEvent(null, null)) throw new UnexpectedStateException(); if (this.am.waitServerReportEvent(null, null)) throw new UnexpectedStateException();
} }
@Ignore @Test // TODO
public void testGoodSplit() throws Exception {
TableName tableName = TableName.valueOf(this.name.getMethodName());
RegionInfo hri = RegionInfoBuilder.newBuilder(tableName)
.setStartKey(Bytes.toBytes(0))
.setEndKey(Bytes.toBytes(2))
.setSplit(false)
.setRegionId(0)
.build();
SplitTableRegionProcedure split =
new SplitTableRegionProcedure(this.master.getMasterProcedureExecutor().getEnvironment(),
hri, Bytes.toBytes(1));
rsDispatcher.setMockRsExecutor(new GoodSplitExecutor());
long st = System.currentTimeMillis();
Thread t = new Thread() {
public void run() {
try {
waitOnFuture(submitProcedure(split));
} catch (Exception e) {
e.printStackTrace();
}
}
};
t.start();
t.join();
long et = System.currentTimeMillis();
float sec = ((et - st) / 1000.0f);
LOG.info(String.format("[T] Splitting in %s", StringUtils.humanTimeDiff(et - st)));
}
@Test @Test
public void testAssignWithGoodExec() throws Exception { public void testAssignWithGoodExec() throws Exception {
// collect AM metrics before test // collect AM metrics before test
@ -865,10 +835,6 @@ public class TestAssignmentManager {
} }
} }
private class GoodSplitExecutor extends NoopRsExecutor {
}
private void collectAssignmentManagerMetrics() { private void collectAssignmentManagerMetrics() {
assignSubmittedCount = assignProcMetrics.getSubmittedCounter().getCount(); assignSubmittedCount = assignProcMetrics.getSubmittedCounter().getCount();
assignFailedCount = assignProcMetrics.getFailedCounter().getCount(); assignFailedCount = assignProcMetrics.getFailedCounter().getCount();