private void doFindEntriesSinceFailureTest(StoreFindToken token, StoreErrorCodes expectedCode) {
    try {
      state.index.findEntriesSince(token, Long.MAX_VALUE);
      fail("Should have failed because token is beyond the end offset in the index");
    } catch (StoreException e) {
      assertEquals("Unexpected StoreErrorCode", expectedCode, e.getErrorCode());
    }
  }
Tests for failure of {@link PersistentIndex#findEntriesSince(FindToken, long)}.
@param token the {@link StoreFindToken} to provide to the function.
@param expectedCode the expected {@link StoreErrorCodes}.
ambry-store/src/test/java/com/github/ambry/store/IndexTest.java