### Question:
Exceptions { public static <T extends Throwable> T appendCause(T exception, Throwable cause) { return (T) exception.initCause(cause); } private  Exceptions(); static RuntimeException tryGetCassandraExceptionCause(RuntimeException exception); static T appendCause(T exception, Throwable cause);  }### Answer:
@Test public void testAppendCause() { IllegalArgumentException ex = new IllegalArgumentException("Ex"); Throwable cause = mock(Throwable.class); IllegalArgumentException result = Exceptions.appendCause(ex, cause); assertThat(result).isSameAs(ex); assertThat(result.getCause()).isSameAs(cause); }