@Test
public void testGetHashCacheKey() throws Exception {

    Result<String> cacheKeyDeletedResult = OpearFile.getHashCacheKey("/no/such/path");
    assertTrue("cacheKey is failure", cacheKeyDeletedResult.isFailure());
    assertTrue("cacheKey failure is FileNotFoundException",
            cacheKeyDeletedResult.findCause(FileNotFoundException.class).isPresent());
    buildDeepTestJar();
    Result<String> cacheKeyResult = OpearFile.getHashCacheKey(deepTestTarget.getPath());
    assertTrue("cacheKey is success", cacheKeyResult.isSuccess());
    String cacheKey = cacheKeyResult.getOrDefault("");
    assertEquals("cacheKey should be 43 characters long: " + cacheKey, 43, cacheKey.length());
    final String pattern = "^[0-9A-Za-z_-]*$";
    assertTrue(String.format("cacheKey %s matches regex %s", cacheKey, pattern), cacheKey.matches(pattern));
}