Class HeaderAssertions
java.lang.Object
org.springframework.test.web.support.AbstractHeaderAssertions<ExchangeResult, WebTestClient.ResponseSpec>
org.springframework.test.web.reactive.server.HeaderAssertions
public class HeaderAssertions
extends AbstractHeaderAssertions<ExchangeResult, WebTestClient.ResponseSpec>
Assertions on headers of the response.
- Since:
- 5.0
- Author:
- Rossen Stoyanchev, Brian Clozel, Sam Brannen, Rob Worsnop
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
assertWithDiagnostics
(Runnable assertion) Subclasses must implement this to assert with diagnostics.protected HttpHeaders
Subclasses must implement this to provide access to response headers.Methods inherited from class AbstractHeaderAssertions
cacheControl, contentDisposition, contentLength, contentType, contentType, contentTypeCompatibleWith, contentTypeCompatibleWith, doesNotExist, exists, expires, getExchangeResult, lastModified, location, value, value, valueEquals, valueEquals, valueEqualsDate, valueMatches, values, values, valuesMatch
-
Method Details
-
getResponseHeaders
Description copied from class:AbstractHeaderAssertions
Subclasses must implement this to provide access to response headers.- Specified by:
getResponseHeaders
in classAbstractHeaderAssertions<ExchangeResult, WebTestClient.ResponseSpec>
-
assertWithDiagnostics
Description copied from class:AbstractHeaderAssertions
Subclasses must implement this to assert with diagnostics.- Specified by:
assertWithDiagnostics
in classAbstractHeaderAssertions<ExchangeResult, WebTestClient.ResponseSpec>
-