Package org.forgerock.util.test.assertj
Class AbstractAssertJPromiseAssert<T,A extends AbstractAssertJPromiseAssert<T,A,S>,S extends org.assertj.core.api.AbstractAssert<S,T>>
java.lang.Object
org.assertj.core.api.AbstractAssert<A,Promise<T,?>>
org.forgerock.util.test.assertj.AbstractAssertJPromiseAssert<T,A,S>
- Type Parameters:
T- The promised type.A- The type of assert that this class is.S- The type of assert that is returned from the succeeded method.
- All Implemented Interfaces:
org.assertj.core.api.Assert<A,,Promise<T, ?>> org.assertj.core.api.Descriptable<A>,org.assertj.core.api.ExtensionPoints<A,Promise<T, ?>>
- Direct Known Subclasses:
AssertJJsonValueAssert.AssertJJsonValuePromiseAssert,AssertJPromiseAssert
public abstract class AbstractAssertJPromiseAssert<T,A extends AbstractAssertJPromiseAssert<T,A,S>,S extends org.assertj.core.api.AbstractAssert<S,T>>
extends org.assertj.core.api.AbstractAssert<A,Promise<T,?>>
Assertion class for a promise. Allows verification of the value that was completed with.
-
Field Summary
Fields inherited from class org.assertj.core.api.AbstractAssert
actual, info, myself, objects, throwUnsupportedExceptionOnEquals -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractAssertJPromiseAssert(Promise<T, ?> promise, Class<A> type) Constructs a new assertion on promise. -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract ScreateSucceededAssert(T actual) Factory method for the succeeded assert class.final org.assertj.core.api.AbstractThrowableAssert<?,? extends Throwable> Asserts that the promise failed.final SAsserts that the promise succeeded.Methods inherited from class org.assertj.core.api.AbstractAssert
actual, areEqual, asInstanceOf, asList, assertionError, asString, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, doesNotHaveSameHashCodeAs, doesNotHaveToString, doesNotHaveToString, doesNotMatch, doesNotMatch, equals, extracting, extracting, failure, failureWithActualExpected, failWithActualExpectedAndMessage, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, hasToString, inBinary, inHexadecimal, is, isElementOfCustomAssert, isEqualTo, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, newListAssertInstance, overridingErrorMessage, overridingErrorMessage, satisfies, satisfies, satisfies, satisfiesAnyOf, satisfiesAnyOf, satisfiesAnyOfForProxy, satisfiesForProxy, setCustomRepresentation, setDescriptionConsumer, setPrintAssertionsDescription, throwAssertionError, usingComparator, usingComparator, usingDefaultComparator, usingEquals, usingEquals, usingRecursiveAssertion, usingRecursiveAssertion, usingRecursiveComparison, usingRecursiveComparison, withFailMessage, withFailMessage, withRepresentation, withThreadDumpOnErrorMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.assertj.core.api.Descriptable
as, as, as, describedAs, describedAs
-
Constructor Details
-
AbstractAssertJPromiseAssert
Constructs a new assertion on promise.- Parameters:
promise- the actual promise to checktype- the type of assertion
-
-
Method Details
-
createSucceededAssert
Factory method for the succeeded assert class.- Parameters:
actual- The promised value.- Returns:
- The
AbstractAssertimplementation.
-
succeeded
Asserts that the promise succeeded.- Returns:
- An
AbstractAssertfor making assertions on the promise's completed value.
-
failedWithException
public final org.assertj.core.api.AbstractThrowableAssert<?,? extends Throwable> failedWithException()Asserts that the promise failed.- Returns:
- A
ThrowableAssertfor making assertions on the promise's failure cause.
-