@Test
public void testMC() throws Exception {

    // move a region to the first RS
    ArrayList<ServerName> serverNameList = getServerNameList();
    assertTrue(serverNameList.size() >= 2);
    ArrayList<HRegionInfo> regionInfoList = getRegionInfoList(tableName);
    assertEquals(1, regionInfoList.size());
    HRegionInfo regionInfo = regionInfoList.get(0);
    ServerName serverName = serverNameList.get(0);
    move(regionInfo, serverName);
    // make 2 store files
    putData(table, "a".getBytes());
    admin.flush(tableName);
    putData(table, "b".getBytes());
    admin.flush(tableName);
    Thread.sleep(3000);
    assertEquals(2, getRegionLoad(regionInfo, serverName).getStorefiles());
    // run MC
    String[] argsParam = {"zookeeper", tableName, "--force-proceed", "--wait", "--test"};
    Args args = new ManagerArgs(argsParam);
    MC command = new MC(admin, args);
    command.run();
    assertRegionName(command);
    // should be 1 store file
    assertEquals(1, getRegionLoad(regionInfo, serverName).getStorefiles());
}