public class ThrowableKt
| Modifier and Type | Method and Description |
|---|---|
static <T extends Throwable> |
cause(Assert<? extends T> $receiver)
Returns an assert on the throwable's cause.
|
static <T extends Throwable> |
hasCause(Assert<? extends T> $receiver,
java.lang.Throwable cause)
Asserts the throwable is similar to the expected cause, checking the type and message.
|
static <T extends Throwable> |
hasCauseInstanceOf(Assert<? extends T> $receiver,
kotlin.reflect.KClass<? extends T> kclass)
Deprecated.
|
static <T extends Throwable> |
hasCauseWithClass(Assert<? extends T> $receiver,
kotlin.reflect.KClass<? extends T> kclass)
Deprecated.
|
static <T extends Throwable> |
hasMessage(Assert<? extends T> $receiver,
java.lang.String message)
Asserts the throwable has the expected message.
|
static <T extends Throwable> |
hasMessageContaining(Assert<? extends T> $receiver,
java.lang.String string)
Deprecated.
|
static <T extends Throwable> |
hasMessageEndingWith(Assert<? extends T> $receiver,
java.lang.String suffix)
Deprecated.
|
static <T extends Throwable> |
hasMessageMatching(Assert<? extends T> $receiver,
kotlin.text.Regex regex)
Deprecated.
|
static <T extends Throwable> |
hasMessageStartingWith(Assert<? extends T> $receiver,
java.lang.String prefix)
Deprecated.
|
static <T extends Throwable> |
hasNoCause(Assert<? extends T> $receiver)
Asserts the throwable has no cause.
|
static <T extends Throwable> |
hasRootCause(Assert<? extends T> $receiver,
java.lang.Throwable cause)
Asserts the throwable is similar to the expected root cause, checking the type and message.
|
static <T extends Throwable> |
hasRootCauseInstanceOf(Assert<? extends T> $receiver,
kotlin.reflect.KClass<? extends T> kclass)
Deprecated.
|
static <T extends Throwable> |
hasRootCauseWithClass(Assert<? extends T> $receiver,
kotlin.reflect.KClass<? extends T> kclass)
Deprecated.
|
static <T extends Throwable> |
message(Assert<? extends T> $receiver)
Returns an assert on the throwable's message.
|
static <T extends Throwable> |
rootCause(Assert<? extends T> $receiver)
Returns an assert on the throwable's root cause.
|
public static <T extends Throwable> Assert<java.lang.String> message(Assert<? extends T> $receiver)
Returns an assert on the throwable's message.
public static <T extends Throwable> Assert<java.lang.Throwable> cause(Assert<? extends T> $receiver)
Returns an assert on the throwable's cause.
public static <T extends Throwable> Assert<java.lang.Throwable> rootCause(Assert<? extends T> $receiver)
Returns an assert on the throwable's root cause.
public static <T extends Throwable> void hasMessage(Assert<? extends T> $receiver, java.lang.String message)
Asserts the throwable has the expected message.
public static <T extends Throwable> void hasCause(Assert<? extends T> $receiver, java.lang.Throwable cause)
Asserts the throwable is similar to the expected cause, checking the type and message.
ThrowableKt.hasNoCausepublic static <T extends Throwable> void hasNoCause(Assert<? extends T> $receiver)
Asserts the throwable has no cause.
ThrowableKt.hasCausepublic static <T extends Throwable> void hasRootCause(Assert<? extends T> $receiver, java.lang.Throwable cause)
Asserts the throwable is similar to the expected root cause, checking the type and message.
public static <T extends Throwable> void hasMessageStartingWith(Assert<? extends T> $receiver, java.lang.String prefix)
Asserts the throwable has a message starting with the expected string.
public static <T extends Throwable> void hasMessageContaining(Assert<? extends T> $receiver, java.lang.String string)
Asserts the throwable has a message containing the expected string.
public static <T extends Throwable> void hasMessageMatching(Assert<? extends T> $receiver, kotlin.text.Regex regex)
Asserts the throwable has a messaging matching the expected regular expression.
public static <T extends Throwable> void hasMessageEndingWith(Assert<? extends T> $receiver, java.lang.String suffix)
Asserts the throwable has a message ending with the expected string.
public static <T extends Throwable> void hasCauseWithClass(Assert<? extends T> $receiver, kotlin.reflect.KClass<? extends T> kclass)
Asserts the throwable's cause matches the expected kotlin class.
public static <T extends Throwable> void hasRootCauseWithClass(Assert<? extends T> $receiver, kotlin.reflect.KClass<? extends T> kclass)
Asserts the throwable's root cause matches the expected kotlin class.
public static <T extends Throwable> void hasCauseInstanceOf(Assert<? extends T> $receiver, kotlin.reflect.KClass<? extends T> kclass)
Asserts the throwable's cause is an instance of the expected kotlin class.