Uses of Annotation Type
org.assertj.core.annotation.CanIgnoreReturnValue
Packages that use CanIgnoreReturnValue
-
Uses of CanIgnoreReturnValue in org.assertj.core.api
Methods in org.assertj.core.api with annotations of type CanIgnoreReturnValueModifier and TypeMethodDescriptionstatic AbstractThrowableAssert<?, ? extends Throwable> Assertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowable(easier done with lambdas).static AbstractThrowableAssert<?, ? extends Throwable> Assertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikeassertThatThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).static AbstractThrowableAssert<?, ? extends Throwable> AssertionsForClassTypes.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowable(easier done with lambdas).static AbstractThrowableAssert<?, ? extends Throwable> AssertionsForClassTypes.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikeassertThatThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).static AbstractThrowableAssert<?, ? extends Throwable> Java6Assertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Deprecated.Allows to capture and then assert on aThrowablemore easily when used with Java 8 lambdas.static AbstractThrowableAssert<?, ? extends Throwable> Java6Assertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Deprecated.Allows to capture and then assert on aThrowablelikeassertThatThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).default AbstractThrowableAssert<?, ? extends Throwable> Java6StandardSoftAssertionsProvider.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowablemore easily when used with Java 8 lambdas.default AbstractThrowableAssert<?, ? extends Throwable> Java6StandardSoftAssertionsProvider.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikeassertThatThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).default AbstractThrowableAssert<?, ? extends Throwable> WithAssertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowable(easier done with lambdas).default AbstractThrowableAssert<?, ? extends Throwable> WithAssertions.assertThatThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikeassertThatThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).static <T> ObjectAssert<T> Assertions.assertWith(T actual, Consumer<T>... requirements) Uses the given instance as the instance under test for all the assertions expressed as the passedConsumer.default <T> ObjectAssert<T> WithAssertions.assertWith(T actual, Consumer<T>... requirements) Uses the given instance as the instance under test for all the assertions expressed as the passedConsumer.<T> TAbstractSoftAssertions.fail()Fails with an empty message to be used in code like:<T> TFails with the given message.<T> TFails with the given message built likeString.format(String, Object...).<T> TFails with the given message and with theThrowablethat caused the failure.<T> TFails with theThrowablethat caused the failure and an empty message.static <T> TAssertions.fail()Throws anAssertionErrorwith an empty message to be used in code like:static <T> TThrows anAssertionErrorwith the given message.static <T> TThrows anAssertionErrorwith the given message built asString.format(String, Object...).static <T> TThrows anAssertionErrorwith the given message and with theThrowablethat caused the failure.static <T> TThrows anAssertionErrorwith theThrowablethat caused the failure and an empty message.static <T> TBDDAssertions.fail()Throws anAssertionErrorwith an empty message to be used in code like:static <T> TThrows anAssertionErrorwith the given message.static <T> TThrows anAssertionErrorwith the given message built asString.format(String, Object...).static <T> TThrows anAssertionErrorwith the given message and with theThrowablethat caused the failure.static <T> TThrows anAssertionErrorwith theThrowablethat caused the failure.static <T> TFail.fail()Throws anAssertionErrorwith an empty message to be used in code like:static <T> TThrows anAssertionErrorwith the given message.static <T> TThrows anAssertionErrorwith the given message built asString.format(String, Object...).static <T> TThrows anAssertionErrorwith the given message and with theThrowablethat caused the failure.static <T> TThrows anAssertionErrorwith theThrowablethat caused the failure.default <T> TWithAssertions.fail()Throws anAssertionErrorwith an empty message to be used in code like:default <T> TThrows anAssertionErrorwith the given message.default <T> TThrows anAssertionErrorwith the given message built asString.format(String, Object...).default <T> TThrows anAssertionErrorwith the given message and with theThrowablethat caused the failure.default <T> TThrows anAssertionErrorwith theThrowablethat caused the failure.static <T> TAssertions.failBecauseExceptionWasNotThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.static <T> TFail.failBecauseExceptionWasNotThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.default <T> TWithAssertions.failBecauseExceptionWasNotThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.static <T> TAssertions.shouldHaveThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.static <T> TBDDAssertions.shouldHaveThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.static <T> TFail.shouldHaveThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.default <T> TWithAssertions.shouldHaveThrown(Class<? extends Throwable> throwableClass) Throws anAssertionErrorwith a message explaining that aThrowableof given class was expected to be thrown but had not been.static AbstractThrowableAssert<?, ? extends Throwable> BDDAssertions.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowable(easier done with lambdas).static AbstractThrowableAssert<?, ? extends Throwable> BDDAssertions.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikethenThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).static AbstractThrowableAssert<?, ? extends Throwable> Java6BDDAssertions.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Deprecated.Allows to capture and then assert on aThrowablemore easily when used with Java 8 lambdas.static AbstractThrowableAssert<?, ? extends Throwable> Java6BDDAssertions.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Deprecated.Allows to capture and then assert on aThrowablelikethenThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).default AbstractThrowableAssert<?, ? extends Throwable> Java6BDDSoftAssertionsProvider.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable) Allows to capture and then assert on aThrowablemore easily when used with Java 8 lambdas.default AbstractThrowableAssert<?, ? extends Throwable> Java6BDDSoftAssertionsProvider.thenThrownBy(ThrowableAssert.ThrowingCallable shouldRaiseThrowable, String description, Object... args) Allows to capture and then assert on aThrowablelikethenThrownBy(ThrowingCallable)but this method let you set the assertion description the same way you do withas(String, Object...).static <T> ObjectAssert<T> Uses the given instance as the instance under test for all the assertions expressed as the passedConsumers.