public class ThrowableAssert extends AbstractThrowableAssert<ThrowableAssert,java.lang.Throwable>
Throwables.
To create a new instance of this class, invoke .
Assertions.assertThat(Throwable)
| Modifier and Type | Class and Description |
|---|---|
static interface |
ThrowableAssert.ThrowingCallable |
throwablesactual, assertionErrorCreator, conditions, info, myself, objects, throwUnsupportedExceptionOnEquals| Constructor and Description |
|---|
ThrowableAssert(java.util.concurrent.Callable<V> runnable) |
ThrowableAssert(java.lang.Throwable actual) |
| Modifier and Type | Method and Description |
|---|---|
private static <V> java.lang.Throwable |
buildThrowableAssertFromCallable(java.util.concurrent.Callable<V> callable) |
static java.lang.Throwable |
catchThrowable(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) |
static <THROWABLE extends java.lang.Throwable> |
catchThrowableOfType(ThrowableAssert.ThrowingCallable shouldRaiseThrowable,
java.lang.Class<THROWABLE> type) |
doesNotThrowAnyException, hasBeenThrown, hasCause, hasCauseExactlyInstanceOf, hasCauseInstanceOf, hasCauseReference, hasMessage, hasMessage, hasMessageContaining, hasMessageContainingAll, hasMessageEndingWith, hasMessageFindingMatch, hasMessageMatching, hasMessageNotContaining, hasMessageNotContainingAny, hasMessageStartingWith, hasNoCause, hasNoSuppressedExceptions, hasRootCause, hasRootCauseExactlyInstanceOf, hasRootCauseInstanceOf, hasStackTraceContaining, hasSuppressedExceptionas, as, extracting, extracting, extracting, extracting, getComparatorsByType, hasAllNullFieldsOrProperties, hasAllNullFieldsOrPropertiesExcept, hasFieldOrProperty, hasFieldOrPropertyWithValue, hasNoNullFieldsOrProperties, hasNoNullFieldsOrPropertiesExcept, isEqualToComparingFieldByField, isEqualToComparingFieldByFieldRecursively, isEqualToComparingOnlyGivenFields, isEqualToIgnoringGivenFields, isEqualToIgnoringNullFields, newObjectAssert, returns, usingComparatorForFields, usingComparatorForType, usingRecursiveComparison, usingRecursiveComparison, withAssertionState, withComparatorByPropertyOrField, withTypeComparatorasInstanceOf, asList, asString, describedAs, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, equals, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, inBinary, inHexadecimal, is, isEqualTo, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, newListAssertInstance, overridingErrorMessage, satisfies, satisfies, satisfiesAnyOf, satisfiesAnyOf, setCustomRepresentation, throwAssertionError, usingComparator, usingComparator, usingDefaultComparator, withFailMessage, withRepresentation, withThreadDumpOnErrorpublic ThrowableAssert(java.lang.Throwable actual)
public ThrowableAssert(java.util.concurrent.Callable<V> runnable)
private static <V> java.lang.Throwable buildThrowableAssertFromCallable(java.util.concurrent.Callable<V> callable)
throws java.lang.AssertionError
java.lang.AssertionErrorpublic static java.lang.Throwable catchThrowable(ThrowableAssert.ThrowingCallable shouldRaiseThrowable)
public static <THROWABLE extends java.lang.Throwable> THROWABLE catchThrowableOfType(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, java.lang.Class<THROWABLE> type)