Package org.assertj.core.api
Class AbstractStandardSoftAssertions
java.lang.Object
org.assertj.core.api.AbstractSoftAssertions
org.assertj.core.api.Java6AbstractStandardSoftAssertions
org.assertj.core.api.AbstractStandardSoftAssertions
- Direct Known Subclasses:
JUnitSoftAssertions
,SoftAssertions
-
Field Summary
Fields inherited from class org.assertj.core.api.AbstractSoftAssertions
proxies
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionassertThat
(Path actual) Creates a new, proxied instance of aPathAssert
assertThat
(Instant actual) Creates a new instance of
.InstantAssert
assertThat
(LocalDate actual) Creates a new instance of
.LocalDateAssert
assertThat
(LocalDateTime actual) Creates a new instance of
.LocalDateTimeAssert
assertThat
(LocalTime actual) Creates a new instance of
.LocalTimeAssert
assertThat
(OffsetDateTime actual) Creates a new instance of
.OffsetDateTimeAssert
assertThat
(OffsetTime actual) Creates a new instance of
.OffsetTimeAssert
assertThat
(ZonedDateTime actual) Creates a new instance of
.ZonedDateTimeAssert
<RESULT> CompletableFutureAssert
<RESULT> assertThat
(CompletableFuture<RESULT> actual) Create assertion forCompletableFuture
.assertThat
(DoublePredicate actual) Create assertion forDoublePredicate
.assertThat
(IntPredicate actual) Create assertion forIntPredicate
.assertThat
(LongPredicate actual) Create assertion forDoublePredicate
.<T> SoftAssertionPredicateAssert
<T> assertThat
(Predicate<T> actual) Create assertion forPredicate
.<VALUE> OptionalAssert
<VALUE> assertThat
(Optional<VALUE> actual) Create assertion forOptional
.assertThat
(OptionalDouble actual) Create assertion forOptionalDouble
.assertThat
(OptionalInt actual) Create assertion forOptionalInt
.assertThat
(OptionalLong actual) Create assertion forOptionalLong
.<ELEMENT,
STREAM extends BaseStream<ELEMENT, STREAM>>
ListAssert<ELEMENT> assertThat
(BaseStream<? extends ELEMENT, STREAM> actual) Creates a new instance of
from the givenListAssert
BaseStream
.Methods inherited from class org.assertj.core.api.Java6AbstractStandardSoftAssertions
assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThat, assertThatCode, assertThatThrownBy
Methods inherited from class org.assertj.core.api.AbstractSoftAssertions
errorsCollected, fail, fail, fail, failBecauseExceptionWasNotThrown, proxy, shouldHaveThrown, wasSuccess
-
Constructor Details
-
AbstractStandardSoftAssertions
public AbstractStandardSoftAssertions()
-
-
Method Details
-
assertThat
Creates a new, proxied instance of aPathAssert
- Parameters:
actual
- the path- Returns:
- the created assertion object
-
assertThat
Create assertion forOptional
.- Type Parameters:
VALUE
- the type of the value contained in theOptional
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Create assertion forOptionalDouble
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Create assertion forOptionalLong
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Create assertion forOptionalInt
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.LocalDateAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.LocalDateTimeAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.ZonedDateTimeAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.LocalTimeAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.OffsetTimeAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.OffsetDateTimeAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Creates a new instance of
.InstantAssert
- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
- Since:
- 3.7.0
-
assertThat
Create assertion forCompletableFuture
.- Type Parameters:
RESULT
- the type of the value contained in theCompletableFuture
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
-
assertThat
Create assertion forPredicate
.- Type Parameters:
T
- the type of the value contained in thePredicate
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
- Since:
- 3.5.0
-
assertThat
Create assertion forIntPredicate
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
- Since:
- 3.5.0
-
assertThat
Create assertion forDoublePredicate
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
- Since:
- 3.5.0
-
assertThat
Create assertion forDoublePredicate
.- Parameters:
actual
- the actual value.- Returns:
- the created assertion object.
- Since:
- 3.5.0
-
assertThat
public <ELEMENT,STREAM extends BaseStream<ELEMENT, ListAssert<ELEMENT> assertThatSTREAM>> (BaseStream<? extends ELEMENT, STREAM> actual) Creates a new instance of
from the givenListAssert
BaseStream
.Be aware that to create the returned
ListAssert
the given theBaseStream
is consumed so it won't be possible to use it again. Calling multiple methods on the returnedListAssert
is safe as it only interacts with theList
built from theBaseStream
.This method accepts
Stream
and primitive stream variantsIntStream
,LongStream
andDoubleStream
.- Parameters:
actual
- the actualBaseStream
value.- Returns:
- the created assertion object.
-