@Test
public void throwsIOException() {

  try {
    ApiExceptions.callAndTranslateApiException(
        ApiFutures.immediateFailedFuture(new IOException()));
    Assert.fail("ApiExceptions should have thrown an exception");
  } catch (UncheckedExecutionException expected) {
    assertThat(expected).hasCauseThat().isInstanceOf(IOException.class);
  }
}