S
- a self reference to the spec typeB
- the body typepublic static interface WebTestClient.BodySpec<B,S extends WebTestClient.BodySpec<B,S>>
Modifier and Type | Method and Description |
---|---|
<T extends S> |
consumeWith(Consumer<EntityExchangeResult<B>> consumer)
Assert the exchange result with the given
Consumer . |
<T extends S> |
isEqualTo(B expected)
Assert the extracted body is equal to the given value.
|
EntityExchangeResult<B> |
returnResult()
Exit the chained API and return an
ExchangeResult with the
decoded response content. |
<T extends S> |
value(Consumer<B> consumer)
Assert the extracted body with a
Consumer . |
<T extends S,R> |
value(Function<B,R> bodyMapper,
Matcher<? super R> matcher)
Transform the extracted the body with a function, e.g.
|
<T extends S> |
value(Matcher<? super B> matcher)
Assert the extracted body with a
Matcher . |
<T extends S> T isEqualTo(B expected)
<T extends S> T value(Matcher<? super B> matcher)
Matcher
.<T extends S,R> T value(Function<B,R> bodyMapper, Matcher<? super R> matcher)
Matcher
.<T extends S> T value(Consumer<B> consumer)
Consumer
.<T extends S> T consumeWith(Consumer<EntityExchangeResult<B>> consumer)
Consumer
.EntityExchangeResult<B> returnResult()
ExchangeResult
with the
decoded response content.