private int findMSB(int n) {
    int msbIndex = 0;

    Assert.assertTrue("Only positive values expected", n > 0);

    while (n > 1) {
      n = (n >> 1);
      msbIndex++;
    }

    return msbIndex;
  }
Unit test for function dropPartitionsInBatches in DDLTask.
ql/src/test/org/apache/hadoop/hive/ql/exec/TestMsckDropPartitionsInBatches.java