Class StatusAssertions
java.lang.Object
org.springframework.test.web.support.AbstractStatusAssertions<ExchangeResult, WebTestClient.ResponseSpec>
org.springframework.test.web.reactive.server.StatusAssertions
public class StatusAssertions
extends AbstractStatusAssertions<ExchangeResult, WebTestClient.ResponseSpec>
Assertions on the response status.
- Since:
 - 5.0
 - Author:
 - Rossen Stoyanchev, Rob Worsnop
 - See Also:
 
- 
Method Summary
Modifier and TypeMethodDescriptionprotected voidassertWithDiagnostics(Runnable assertion) Subclasses must implement this to assert with diagnostics.protected HttpStatusCodeSubclasses must implement this to provide access to the response status.Deprecated, for removal: This API element is subject to removal in a future version.Methods inherited from class AbstractStatusAssertions
getExchangeResult, getResponseSpec, is1xxInformational, is2xxSuccessful, is3xxRedirection, is4xxClientError, is5xxServerError, isAccepted, isBadRequest, isCreated, isEqualTo, isEqualTo, isForbidden, isFound, isNoContent, isNotFound, isNotModified, isOk, isPermanentRedirect, isSeeOther, isTemporaryRedirect, isUnauthorized, reasonEquals, value 
- 
Method Details
- 
getStatus
Description copied from class:AbstractStatusAssertionsSubclasses must implement this to provide access to the response status.- Specified by:
 getStatusin classAbstractStatusAssertions<ExchangeResult, WebTestClient.ResponseSpec>
 - 
assertWithDiagnostics
Description copied from class:AbstractStatusAssertionsSubclasses must implement this to assert with diagnostics.- Specified by:
 assertWithDiagnosticsin classAbstractStatusAssertions<ExchangeResult, WebTestClient.ResponseSpec>
 - 
value
@Deprecated(since="7.0", forRemoval=true) public WebTestClient.ResponseSpec value(Matcher<? super Integer> matcher) Deprecated, for removal: This API element is subject to removal in a future version.in favor ofConsumer-based variantsMatch the response status value with a Hamcrest matcher.- Parameters:
 matcher- the matcher to use
 
 - 
 
Consumer-based variants