@Test
public void testTryGetFutureValue()
        throws Exception
{

    assertGetUnchecked(future -> {
        Optional<?> optional = tryGetFutureValue(future);
        if (optional.isPresent()) {
            return optional.get();
        }
        // null value is also absent
        assertNull(getFutureValue(future));
        return null;
    });
    assertEquals(tryGetFutureValue(new CompletableFuture<>()), Optional.empty());
}