@BeforeClass
  public static void setupClass() throws Exception {
    hiveConf = new HiveConfForTest(TestMsckCreatePartitionsInBatches.class);
    hiveConf.setIntVar(ConfVars.HIVE_MSCK_REPAIR_BATCH_SIZE, 5);
    hiveConf.setVar(HiveConf.ConfVars.HIVE_AUTHORIZATION_MANAGER,
      "org.apache.hadoop.hive.ql.security.authorization.plugin.sqlstd.SQLStdHiveAuthorizerFactory");
    SessionState.start(hiveConf);
    db = new HiveMetaStoreClient(hiveConf);
    msck = new Msck( false, false);
    msck.init(Msck.getMsckConf(hiveConf));
  }
Unit test for function dropPartitionsInBatches in DDLTask.
ql/src/test/org/apache/hadoop/hive/ql/exec/TestMsckDropPartitionsInBatches.java