Module methanol.testing
Class RequestVerifier
java.lang.Object
com.github.mizosoft.methanol.testing.verifiers.RequestVerifier
A small DSL for testing
HttpRequests
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptioncontainsHeader
(String name, String value) containsHeaders
(HttpHeaders headers) containsHeadersExactly
(String... headers) containsHeadersExactly
(HttpHeaders headers) <T> RequestVerifier
containsTag
(TypeRef<T> type, T value) <T> RequestVerifier
containsTag
(Class<T> type, T value) doesNotContainTag
(Class<?> type) hasBodyPublisher
(HttpRequest.BodyPublisher publisher) hasBodyPublisher
(Optional<HttpRequest.BodyPublisher> publisher) hasExpectContinue
(boolean value) hasTimeout
(Duration timeout) hasTimeout
(Optional<Duration> timeout) hasVersion
(HttpClient.Version version) hasVersion
(Optional<HttpClient.Version> version) isDeeplyEqualTo
(HttpRequest other) isDELETE()
isEqualTo
(HttpRequest other) isGET()
isPATCH()
isPOST()
isPUT()
-
Constructor Details
-
RequestVerifier
-
-
Method Details
-
hasMethod
-
isGET
-
isPOST
-
isPUT
-
isDELETE
-
isPATCH
-
hasBodyPublisher
-
hasBodyPublisher
@CanIgnoreReturnValue public RequestVerifier hasBodyPublisher(Optional<HttpRequest.BodyPublisher> publisher) -
hasUri
-
hasUri
-
hasExpectContinue
-
hasVersion
-
hasVersion
-
containsHeader
-
containsHeadersExactly
-
containsHeadersExactly
-
hasEmptyHeaders
-
containsHeaders
-
containsTag
-
containsTag
-
doesNotContainTag
-
hasTimeout
-
hasTimeout
-
hasNoBody
-
hasNoTimeout
-
hasNoVersion
-
isEqualTo
-
isDeeplyEqualTo
-