@Test
  public void testSelectManifestFilesWithEmptyManifests() {
    Set<String> emptyFiles = new HashSet<>();
    emptyFiles.add("000001_0.manifest");
    emptyFiles.add("000001_2.manifest");
    emptyFiles.add("000002_2.manifest");
    FileStatus[] manifestFiles = generateTestNotEmptyFileStatuses(emptyFiles, "000001_1.manifest", "000001_0.manifest",
        "000001_3.manifest", "000001_2.manifest", "000002_0.manifest", "000002_1.manifest", "000002_2.manifest");
    Set<String> expectedPathes = getExpectedPathes("000001_3.manifest", "000002_1.manifest");
    List<Path> foundManifestFiles = Utilities.selectManifestFiles(manifestFiles);
    Set<String> resultPathes = getResultPathes(foundManifestFiles);
    assertEquals(expectedPathes, resultPathes);
  }
This test tests that Utilities.get*Tasks do not repeat themselves in the process
of extracting tasks from a given set of root tasks when given DAGs that can have
multiple paths, such as the case with Diamond-shaped DAGs common to replication.
ql/src/test/org/apache/hadoop/hive/ql/exec/TestUtilities.java