@Test
  public void testLoadFilesAfterSplit() throws Exception {
    // If stripes are good but have non-open ends, they must be treated as open ends.
    MockHStoreFile sf = createFile(KEY_B, KEY_C);
    StripeStoreFileManager manager = createManager(al(createFile(OPEN_KEY, KEY_B), sf));
    assertEquals(0, manager.getLevel0Files().size());
    // Here, [B, C] is logically [B, inf), so we should be able to compact it to that only.
    verifyInvalidCompactionScenario(manager, al(sf), al(createFile(KEY_B, KEY_C)));
    manager.addCompactionResults(al(sf), al(createFile(KEY_B, OPEN_KEY)));
    manager.removeCompactedFiles(al(sf));
    // Do the same for other variants.
    manager = createManager(al(sf, createFile(KEY_C, OPEN_KEY)));
    verifyInvalidCompactionScenario(manager, al(sf), al(createFile(KEY_B, KEY_C)));
    manager.addCompactionResults(al(sf), al(createFile(OPEN_KEY, KEY_C)));
    manager.removeCompactedFiles(al(sf));
    manager = createManager(al(sf));
    verifyInvalidCompactionScenario(manager, al(sf), al(createFile(KEY_B, KEY_C)));
    manager.addCompactionResults(al(sf), al(createFile(OPEN_KEY, OPEN_KEY)));
  }
Verifies scenario for finding a split point.
@param splitPointAfter    Stripe to expect the split point at/after.
@param shouldSplitStripe  If true, the split point is expected in the middle of the above
                          stripe; if false, should be at the end.
@param splitRatioToVerify Maximum split imbalance ratio.
@param sizes              Stripe sizes.
hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestStripeStoreFileManager.java