public class StatusResultMatchers
extends java.lang.Object
このクラスのインスタンスは通常、MockMvcResultMatchers.status()
を介してアクセスされます。
修飾子 | コンストラクターと説明 |
---|---|
protected | StatusResultMatchers() protected コンストラクター。 |
修飾子と型 | メソッドと説明 |
---|---|
ResultMatcher | is(int status) レスポンスステータスコードが整数値と等しいことをアサートします。 |
ResultMatcher | is(org.hamcrest.Matcher<java.lang.Integer> matcher) 指定された Hamcrest Matcher でレスポンスステータスコードをアサートします。 |
ResultMatcher | is1xxInformational() レスポンスステータスコードが 1xx の範囲であることをアサートします。 |
ResultMatcher | is2xxSuccessful() レスポンスステータスコードが 2xx の範囲であることをアサートします。 |
ResultMatcher | is3xxRedirection() レスポンスステータスコードが 3xx の範囲であることをアサートします。 |
ResultMatcher | is4xxClientError() レスポンスステータスコードが 4xx の範囲であることをアサートします。 |
ResultMatcher | is5xxServerError() レスポンスステータスコードが 5xx の範囲であることをアサートします。 |
ResultMatcher | isAccepted() レスポンスステータスコードが HttpStatus.ACCEPTED (202) であることをアサートします。 |
ResultMatcher | isAlreadyReported() レスポンスステータスコードが HttpStatus.ALREADY_REPORTED (208) であることをアサートします。 |
ResultMatcher | isBadGateway() レスポンスステータスコードが HttpStatus.BAD_GATEWAY (502) であることをアサートします。 |
ResultMatcher | isBadRequest() レスポンスステータスコードが HttpStatus.BAD_REQUEST (400) であることをアサートします。 |
ResultMatcher | isBandwidthLimitExceeded() レスポンスステータスコードが HttpStatus.BANDWIDTH_LIMIT_EXCEEDED (509) であることをアサートします。 |
ResultMatcher | isCheckpoint() レスポンスステータスコードが HttpStatus.CHECKPOINT (103) であることをアサートします。 |
ResultMatcher | isConflict() レスポンスステータスコードが HttpStatus.CONFLICT (409) であることをアサートします。 |
ResultMatcher | isContinue() レスポンスステータスコードが HttpStatus.CONTINUE (100) であることをアサートします。 |
ResultMatcher | isCreated() レスポンスステータスコードが HttpStatus.CREATED (201) であることをアサートします。 |
ResultMatcher | isDestinationLocked() 使用すべきではありません。 HttpStatus.DESTINATION_LOCKED の廃止に対応 |
ResultMatcher | isExpectationFailed() レスポンスステータスコードが HttpStatus.EXPECTATION_FAILED (417) であることをアサートします。 |
ResultMatcher | isFailedDependency() レスポンスステータスコードが HttpStatus.FAILED_DEPENDENCY (424) であることをアサートします。 |
ResultMatcher | isForbidden() レスポンスステータスコードが HttpStatus.FORBIDDEN (403) であることをアサートします。 |
ResultMatcher | isFound() レスポンスステータスコードが HttpStatus.FOUND (302) であることをアサートします。 |
ResultMatcher | isGatewayTimeout() レスポンスステータスコードが HttpStatus.GATEWAY_TIMEOUT (504) であることをアサートします。 |
ResultMatcher | isGone() レスポンスステータスコードが HttpStatus.GONE (410) であることをアサートします。 |
ResultMatcher | isHttpVersionNotSupported() レスポンスステータスコードが HttpStatus.HTTP_VERSION_NOT_SUPPORTED (505) であることをアサートします。 |
ResultMatcher | isIAmATeapot() レスポンスステータスコードが HttpStatus.I_AM_A_TEAPOT (418) であることをアサートします。 |
ResultMatcher | isImUsed() レスポンスステータスコードが HttpStatus.IM_USED (226) であることをアサートします。 |
ResultMatcher | isInsufficientSpaceOnResource() 使用すべきではありません。 HttpStatus.INSUFFICIENT_SPACE_ON_RESOURCE の廃止に対応 |
ResultMatcher | isInsufficientStorage() レスポンスステータスコードが HttpStatus.INSUFFICIENT_STORAGE (507) であることをアサートします。 |
ResultMatcher | isInternalServerError() レスポンスステータスコードが HttpStatus.INTERNAL_SERVER_ERROR (500) であることをアサートします。 |
ResultMatcher | isLengthRequired() レスポンスステータスコードが HttpStatus.LENGTH_REQUIRED (411) であることをアサートします。 |
ResultMatcher | isLocked() レスポンスステータスコードが HttpStatus.LOCKED (423) であることをアサートします。 |
ResultMatcher | isLoopDetected() レスポンスステータスコードが HttpStatus.LOOP_DETECTED (508) であることをアサートします。 |
ResultMatcher | isMethodFailure() 使用すべきではありません。 HttpStatus.METHOD_FAILURE の廃止に対応 |
ResultMatcher | isMethodNotAllowed() レスポンスステータスコードが HttpStatus.METHOD_NOT_ALLOWED (405) であることをアサートします。 |
ResultMatcher | isMovedPermanently() レスポンスステータスコードが HttpStatus.MOVED_PERMANENTLY (301) であることをアサートします。 |
ResultMatcher | isMovedTemporarily() 使用すべきではありません。 isFound() を推奨 |
ResultMatcher | isMultipleChoices() レスポンスステータスコードが HttpStatus.MULTIPLE_CHOICES (300) であることをアサートします。 |
ResultMatcher | isMultiStatus() レスポンスステータスコードが HttpStatus.MULTI_STATUS (207) であることをアサートします。 |
ResultMatcher | isNetworkAuthenticationRequired() レスポンスステータスコードが HttpStatus.NETWORK_AUTHENTICATION_REQUIRED (511) であることをアサートします。 |
ResultMatcher | isNoContent() レスポンスステータスコードが HttpStatus.NO_CONTENT (204) であることをアサートします。 |
ResultMatcher | isNonAuthoritativeInformation() レスポンスステータスコードが HttpStatus.NON_AUTHORITATIVE_INFORMATION (203) であることをアサートします。 |
ResultMatcher | isNotAcceptable() レスポンスステータスコードが HttpStatus.NOT_ACCEPTABLE (406) であることをアサートします。 |
ResultMatcher | isNotExtended() レスポンスステータスコードが HttpStatus.NOT_EXTENDED (510) であることをアサートします。 |
ResultMatcher | isNotFound() レスポンスステータスコードが HttpStatus.NOT_FOUND (404) であることをアサートします。 |
ResultMatcher | isNotImplemented() レスポンスステータスコードが HttpStatus.NOT_IMPLEMENTED (501) であることをアサートします。 |
ResultMatcher | isNotModified() レスポンスステータスコードが HttpStatus.NOT_MODIFIED (304) であることをアサートします。 |
ResultMatcher | isOk() レスポンスステータスコードが HttpStatus.OK (200) であることをアサートします。 |
ResultMatcher | isPartialContent() レスポンスステータスコードが HttpStatus.PARTIAL_CONTENT (206) であることをアサートします。 |
ResultMatcher | isPayloadTooLarge() レスポンスステータスコードが HttpStatus.PAYLOAD_TOO_LARGE (413) であることをアサートします。 |
ResultMatcher | isPaymentRequired() レスポンスステータスコードが HttpStatus.PAYMENT_REQUIRED (402) であることをアサートします。 |
ResultMatcher | isPermanentRedirect() レスポンスステータスコードが HttpStatus.PERMANENT_REDIRECT (308) であることをアサートします。 |
ResultMatcher | isPreconditionFailed() レスポンスステータスコードが HttpStatus.PRECONDITION_FAILED (412) であることをアサートします。 |
ResultMatcher | isPreconditionRequired() レスポンスステータスコードが HttpStatus.PRECONDITION_REQUIRED (428) であることをアサートします。 |
ResultMatcher | isProcessing() レスポンスステータスコードが HttpStatus.PROCESSING (102) であることをアサートします。 |
ResultMatcher | isProxyAuthenticationRequired() レスポンスステータスコードが HttpStatus.PROXY_AUTHENTICATION_REQUIRED (407) であることをアサートします。 |
ResultMatcher | isRequestedRangeNotSatisfiable() レスポンスステータスコードが HttpStatus.REQUESTED_RANGE_NOT_SATISFIABLE (416) であることをアサートします。 |
ResultMatcher | isRequestEntityTooLarge() 使用すべきではありません。 HttpStatus.REQUEST_ENTITY_TOO_LARGE の廃止に対応 |
ResultMatcher | isRequestHeaderFieldsTooLarge() レスポンスステータスコードが HttpStatus.REQUEST_HEADER_FIELDS_TOO_LARGE (431) であることをアサートします。 |
ResultMatcher | isRequestTimeout() レスポンスステータスコードが HttpStatus.REQUEST_TIMEOUT (408) であることをアサートします。 |
ResultMatcher | isRequestUriTooLong() 使用すべきではありません。 HttpStatus.REQUEST_URI_TOO_LONG の廃止に対応 |
ResultMatcher | isResetContent() レスポンスステータスコードが HttpStatus.RESET_CONTENT (205) であることをアサートします。 |
ResultMatcher | isSeeOther() レスポンスステータスコードが HttpStatus.SEE_OTHER (303) であることをアサートします。 |
ResultMatcher | isServiceUnavailable() レスポンスステータスコードが HttpStatus.SERVICE_UNAVAILABLE (503) であることをアサートします。 |
ResultMatcher | isSwitchingProtocols() レスポンスステータスコードが HttpStatus.SWITCHING_PROTOCOLS (101) であることをアサートします。 |
ResultMatcher | isTemporaryRedirect() レスポンスステータスコードが HttpStatus.TEMPORARY_REDIRECT (307) であることをアサートします。 |
ResultMatcher | isTooManyRequests() レスポンスステータスコードが HttpStatus.TOO_MANY_REQUESTS (429) であることをアサートします。 |
ResultMatcher | isUnauthorized() レスポンスステータスコードが HttpStatus.UNAUTHORIZED (401) であることをアサートします。 |
ResultMatcher | isUnavailableForLegalReasons() レスポンスステータスコードが HttpStatus.UNAVAILABLE_FOR_LEGAL_REASONS (451) であることをアサートします。 |
ResultMatcher | isUnprocessableEntity() レスポンスステータスコードが HttpStatus.UNPROCESSABLE_ENTITY (422) であることをアサートします。 |
ResultMatcher | isUnsupportedMediaType() レスポンスステータスコードが HttpStatus.UNSUPPORTED_MEDIA_TYPE (415) であることをアサートします。 |
ResultMatcher | isUpgradeRequired() レスポンスステータスコードが HttpStatus.UPGRADE_REQUIRED (426) であることをアサートします。 |
ResultMatcher | isUriTooLong() レスポンスステータスコードが HttpStatus.REQUEST_URI_TOO_LONG (414) であることをアサートします。 |
ResultMatcher | isUseProxy() 使用すべきではありません。 HttpStatus.USE_PROXY の廃止に対応 |
ResultMatcher | isVariantAlsoNegotiates() レスポンスステータスコードが HttpStatus.VARIANT_ALSO_NEGOTIATES (506) であることをアサートします。 |
ResultMatcher | reason(org.hamcrest.Matcher<? super java.lang.String> matcher) 指定された Hamcrest Matcher でサーブレットレスポンスエラーメッセージをアサートします。 |
ResultMatcher | reason(java.lang.String reason) サーブレットレスポンスエラーメッセージをアサートします。 |
protected StatusResultMatchers()
MockMvcResultMatchers.status()
を使用します。public ResultMatcher is(org.hamcrest.Matcher<java.lang.Integer> matcher)
Matcher
でレスポンスステータスコードをアサートします。public ResultMatcher is(int status)
public ResultMatcher is1xxInformational()
public ResultMatcher is2xxSuccessful()
public ResultMatcher is3xxRedirection()
public ResultMatcher is4xxClientError()
public ResultMatcher is5xxServerError()
public ResultMatcher reason(org.hamcrest.Matcher<? super java.lang.String> matcher)
Matcher
でサーブレットレスポンスエラーメッセージをアサートします。public ResultMatcher reason(java.lang.String reason)
public ResultMatcher isContinue()
HttpStatus.CONTINUE
(100) であることをアサートします。public ResultMatcher isSwitchingProtocols()
HttpStatus.SWITCHING_PROTOCOLS
(101) であることをアサートします。public ResultMatcher isProcessing()
HttpStatus.PROCESSING
(102) であることをアサートします。public ResultMatcher isCheckpoint()
HttpStatus.CHECKPOINT
(103) であることをアサートします。public ResultMatcher isOk()
HttpStatus.OK
(200) であることをアサートします。public ResultMatcher isCreated()
HttpStatus.CREATED
(201) であることをアサートします。public ResultMatcher isAccepted()
HttpStatus.ACCEPTED
(202) であることをアサートします。public ResultMatcher isNonAuthoritativeInformation()
HttpStatus.NON_AUTHORITATIVE_INFORMATION
(203) であることをアサートします。public ResultMatcher isNoContent()
HttpStatus.NO_CONTENT
(204) であることをアサートします。public ResultMatcher isResetContent()
HttpStatus.RESET_CONTENT
(205) であることをアサートします。public ResultMatcher isPartialContent()
HttpStatus.PARTIAL_CONTENT
(206) であることをアサートします。public ResultMatcher isMultiStatus()
HttpStatus.MULTI_STATUS
(207) であることをアサートします。public ResultMatcher isAlreadyReported()
HttpStatus.ALREADY_REPORTED
(208) であることをアサートします。public ResultMatcher isImUsed()
HttpStatus.IM_USED
(226) であることをアサートします。public ResultMatcher isMultipleChoices()
HttpStatus.MULTIPLE_CHOICES
(300) であることをアサートします。public ResultMatcher isMovedPermanently()
HttpStatus.MOVED_PERMANENTLY
(301) であることをアサートします。public ResultMatcher isFound()
HttpStatus.FOUND
(302) であることをアサートします。@Deprecated public ResultMatcher isMovedTemporarily()
HttpStatus.MOVED_TEMPORARILY
(302) であることをアサートします。isFound()
public ResultMatcher isSeeOther()
HttpStatus.SEE_OTHER
(303) であることをアサートします。public ResultMatcher isNotModified()
HttpStatus.NOT_MODIFIED
(304) であることをアサートします。@Deprecated public ResultMatcher isUseProxy()
HttpStatus.USE_PROXY
の非推奨に一致します。HttpStatus.USE_PROXY
(305) であることをアサートします。public ResultMatcher isTemporaryRedirect()
HttpStatus.TEMPORARY_REDIRECT
(307) であることをアサートします。public ResultMatcher isPermanentRedirect()
HttpStatus.PERMANENT_REDIRECT
(308) であることをアサートします。public ResultMatcher isBadRequest()
HttpStatus.BAD_REQUEST
(400) であることをアサートします。public ResultMatcher isUnauthorized()
HttpStatus.UNAUTHORIZED
(401) であることをアサートします。public ResultMatcher isPaymentRequired()
HttpStatus.PAYMENT_REQUIRED
(402) であることをアサートします。public ResultMatcher isForbidden()
HttpStatus.FORBIDDEN
(403) であることをアサートします。public ResultMatcher isNotFound()
HttpStatus.NOT_FOUND
(404) であることをアサートします。public ResultMatcher isMethodNotAllowed()
HttpStatus.METHOD_NOT_ALLOWED
(405) であることをアサートします。public ResultMatcher isNotAcceptable()
HttpStatus.NOT_ACCEPTABLE
(406) であることをアサートします。public ResultMatcher isProxyAuthenticationRequired()
HttpStatus.PROXY_AUTHENTICATION_REQUIRED
(407) であることをアサートします。public ResultMatcher isRequestTimeout()
HttpStatus.REQUEST_TIMEOUT
(408) であることをアサートします。public ResultMatcher isConflict()
HttpStatus.CONFLICT
(409) であることをアサートします。public ResultMatcher isGone()
HttpStatus.GONE
(410) であることをアサートします。public ResultMatcher isLengthRequired()
HttpStatus.LENGTH_REQUIRED
(411) であることをアサートします。public ResultMatcher isPreconditionFailed()
HttpStatus.PRECONDITION_FAILED
(412) であることをアサートします。public ResultMatcher isPayloadTooLarge()
HttpStatus.PAYLOAD_TOO_LARGE
(413) であることをアサートします。@Deprecated public ResultMatcher isRequestEntityTooLarge()
HttpStatus.REQUEST_ENTITY_TOO_LARGE
の非推奨に一致します。HttpStatus.REQUEST_ENTITY_TOO_LARGE
(413) であることをアサートします。isPayloadTooLarge()
public ResultMatcher isUriTooLong()
HttpStatus.REQUEST_URI_TOO_LONG
(414) であることをアサートします。@Deprecated public ResultMatcher isRequestUriTooLong()
HttpStatus.REQUEST_URI_TOO_LONG
の非推奨に一致します。HttpStatus.REQUEST_URI_TOO_LONG
(414) であることをアサートします。isUriTooLong()
public ResultMatcher isUnsupportedMediaType()
HttpStatus.UNSUPPORTED_MEDIA_TYPE
(415) であることをアサートします。public ResultMatcher isRequestedRangeNotSatisfiable()
HttpStatus.REQUESTED_RANGE_NOT_SATISFIABLE
(416) であることをアサートします。public ResultMatcher isExpectationFailed()
HttpStatus.EXPECTATION_FAILED
(417) であることをアサートします。public ResultMatcher isIAmATeapot()
HttpStatus.I_AM_A_TEAPOT
(418) であることをアサートします。@Deprecated public ResultMatcher isInsufficientSpaceOnResource()
HttpStatus.INSUFFICIENT_SPACE_ON_RESOURCE
の非推奨に一致します。HttpStatus.INSUFFICIENT_SPACE_ON_RESOURCE
(419) であることをアサートします。@Deprecated public ResultMatcher isMethodFailure()
HttpStatus.METHOD_FAILURE
の非推奨に一致します。HttpStatus.METHOD_FAILURE
(420) であることをアサートします。@Deprecated public ResultMatcher isDestinationLocked()
HttpStatus.DESTINATION_LOCKED
の非推奨に一致します。HttpStatus.DESTINATION_LOCKED
(421) であることをアサートします。public ResultMatcher isUnprocessableEntity()
HttpStatus.UNPROCESSABLE_ENTITY
(422) であることをアサートします。public ResultMatcher isLocked()
HttpStatus.LOCKED
(423) であることをアサートします。public ResultMatcher isFailedDependency()
HttpStatus.FAILED_DEPENDENCY
(424) であることをアサートします。public ResultMatcher isUpgradeRequired()
HttpStatus.UPGRADE_REQUIRED
(426) であることをアサートします。public ResultMatcher isPreconditionRequired()
HttpStatus.PRECONDITION_REQUIRED
(428) であることをアサートします。public ResultMatcher isTooManyRequests()
HttpStatus.TOO_MANY_REQUESTS
(429) であることをアサートします。public ResultMatcher isRequestHeaderFieldsTooLarge()
HttpStatus.REQUEST_HEADER_FIELDS_TOO_LARGE
(431) であることをアサートします。public ResultMatcher isUnavailableForLegalReasons()
HttpStatus.UNAVAILABLE_FOR_LEGAL_REASONS
(451) であることをアサートします。public ResultMatcher isInternalServerError()
HttpStatus.INTERNAL_SERVER_ERROR
(500) であることをアサートします。public ResultMatcher isNotImplemented()
HttpStatus.NOT_IMPLEMENTED
(501) であることをアサートします。public ResultMatcher isBadGateway()
HttpStatus.BAD_GATEWAY
(502) であることをアサートします。public ResultMatcher isServiceUnavailable()
HttpStatus.SERVICE_UNAVAILABLE
(503) であることをアサートします。public ResultMatcher isGatewayTimeout()
HttpStatus.GATEWAY_TIMEOUT
(504) であることをアサートします。public ResultMatcher isHttpVersionNotSupported()
HttpStatus.HTTP_VERSION_NOT_SUPPORTED
(505) であることをアサートします。public ResultMatcher isVariantAlsoNegotiates()
HttpStatus.VARIANT_ALSO_NEGOTIATES
(506) であることをアサートします。public ResultMatcher isInsufficientStorage()
HttpStatus.INSUFFICIENT_STORAGE
(507) であることをアサートします。public ResultMatcher isLoopDetected()
HttpStatus.LOOP_DETECTED
(508) であることをアサートします。public ResultMatcher isBandwidthLimitExceeded()
HttpStatus.BANDWIDTH_LIMIT_EXCEEDED
(509) であることをアサートします。public ResultMatcher isNotExtended()
HttpStatus.NOT_EXTENDED
(510) であることをアサートします。public ResultMatcher isNetworkAuthenticationRequired()
HttpStatus.NETWORK_AUTHENTICATION_REQUIRED
(511) であることをアサートします。