@Test
  public void testAlterTablePartitionLocation_alter5() throws Exception {
    String[] testNames = new String[] {"alter5.q"};

    File[] qfiles = setupQFiles(testNames);

    QTestUtil[] qt = new QTestUtil[qfiles.length];

    for (int i = 0; i < qfiles.length; i++) {
      qt[i] = new CheckResults(resDir, logDir, MiniClusterType.TEZ_LOCAL, "parta");
      qt[i].postInit();
      qt[i].newSession();
      qt[i].setInputFile(qfiles[i]);
      qt[i].clearTestSideEffects();
    }

    boolean success = QTestRunnerUtils.queryListRunnerSingleThreaded(qfiles, qt);
    if (!success) {
      fail("One or more queries failed");
    }
  }
Verify that the location of the partition is valid. In this case
the path should end in "parta" and not "dt=a" (the default).
itests/hive-unit/src/test/java/org/apache/hadoop/hive/ql/TestLocationQueries.java