Package org.assertj.core.api
Class ThrowableAssert
- java.lang.Object
-
- org.assertj.core.api.AbstractAssert<SELF,ACTUAL>
-
- org.assertj.core.api.AbstractObjectAssert<SELF,ACTUAL>
-
- org.assertj.core.api.AbstractThrowableAssert<ThrowableAssert,Throwable>
-
- org.assertj.core.api.ThrowableAssert
-
- All Implemented Interfaces:
Assert<ThrowableAssert,Throwable>,Descriptable<ThrowableAssert>,ExtensionPoints<ThrowableAssert,Throwable>
public class ThrowableAssert extends AbstractThrowableAssert<ThrowableAssert,Throwable>
Assertion methods forThrowables.To create a new instance of this class, invoke
.Assertions.assertThat(Throwable)- Author:
- David DIDIER, Alex Ruiz, Joel Costigliola, Mikhail Mazursky
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceThrowableAssert.ThrowingCallable
-
Field Summary
-
Fields inherited from class org.assertj.core.api.AbstractAssert
actual, info, myself
-
-
Constructor Summary
Constructors Constructor Description ThrowableAssert(Throwable actual)ThrowableAssert(Callable<V> runnable)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ThrowablecatchThrowable(ThrowableAssert.ThrowingCallable shouldRaiseThrowable)-
Methods inherited from class org.assertj.core.api.AbstractThrowableAssert
doesNotThrowAnyException, hasBeenThrown, hasCause, hasCauseExactlyInstanceOf, hasCauseInstanceOf, hasMessage, hasMessage, hasMessageContaining, hasMessageEndingWith, hasMessageMatching, hasMessageStartingWith, hasNoCause, hasNoSuppressedExceptions, hasRootCauseExactlyInstanceOf, hasRootCauseInstanceOf, hasStackTraceContaining, hasSuppressedException
-
Methods inherited from class org.assertj.core.api.AbstractObjectAssert
as, as, defaultTypeComparators, extracting, extracting, hasFieldOrProperty, hasFieldOrPropertyWithValue, hasNoNullFieldsOrProperties, hasNoNullFieldsOrPropertiesExcept, isEqualToComparingFieldByField, isEqualToComparingFieldByFieldRecursively, isEqualToComparingOnlyGivenFields, isEqualToIgnoringGivenFields, isEqualToIgnoringNullFields, returns, usingComparatorForFields, usingComparatorForType
-
Methods inherited from class org.assertj.core.api.AbstractAssert
asList, asString, describedAs, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, equals, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, 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, overridingErrorMessage, satisfies, setCustomRepresentation, throwAssertionError, usingComparator, usingDefaultComparator, withFailMessage, withRepresentation, withThreadDumpOnError
-
-
-
-
Method Detail
-
catchThrowable
public static Throwable catchThrowable(ThrowableAssert.ThrowingCallable shouldRaiseThrowable)
-
-