Top Description Fields Constructors Methods
org.assertj.core.error

public Class ShouldHaveRootCauseExactlyInstance

extends BasicErrorMessageFactory
Class Inheritance
Static Imports
org.assertj.core.util.Strings.escapePercent, .Throwables.getStackTrace

Creates an error message indicating that an assertion that verifies that a Throwable have a root cause exactly instance of a certain type.
Author
Jean-Christophe Gay

Field Summary

Inherited from org.assertj.core.error.BasicErrorMessageFactory:
argumentsformatformatter

Constructor Summary

AccessConstructor and Description
private
ShouldHaveRootCauseExactlyInstance(Throwable actual, Class<? extends Throwable> expectedCauseType)

private
ShouldHaveRootCauseExactlyInstance(Class<? extends Throwable> expectedCauseType, Throwable actual)

Method Summary

Modifier and TypeMethod and Description
public static ErrorMessageFactory

Returns:

the created ErrorMessageFactory.
shouldHaveRootCauseExactlyInstance
(Throwable
the actual value in the failed assertion.
actual
,
Class<? extends Throwable>
the expected cause instance.
expectedCauseType
)

Creates a new org.assertj.core.error.BasicErrorMessageFactory.

Inherited from org.assertj.core.error.BasicErrorMessageFactory:
createcreatecreateequalshashCodetoStringunquotedString

Constructor Detail

ShouldHaveRootCauseExactlyInstanceback to summary
private ShouldHaveRootCauseExactlyInstance(Throwable actual, Class<? extends Throwable> expectedCauseType)
ShouldHaveRootCauseExactlyInstanceback to summary
private ShouldHaveRootCauseExactlyInstance(Class<? extends Throwable> expectedCauseType, Throwable actual)

Method Detail

shouldHaveRootCauseExactlyInstanceback to summary
public static ErrorMessageFactory shouldHaveRootCauseExactlyInstance(Throwable actual, Class<? extends Throwable> expectedCauseType)

Creates a new org.assertj.core.error.BasicErrorMessageFactory.

Parameters
actual:Throwable

the actual value in the failed assertion.

expectedCauseType:Class<? extends Throwable>

the expected cause instance.

Returns:ErrorMessageFactory

the created ErrorMessageFactory.