package strikt.spring
Fields
| Name | Description |
|---|---|
val contentType: Assertion.Builder
|
Maps this assertion to an assertion on the content type of the servlet
response. If the subject has no |
Methods
isCompatibleWith
infix fun <T> Assertion.Builder
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
Parameters
| Name | Description |
|---|---|
expected: MediaType
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs1xxInformational
fun <T> Assertion.Builder
Asserts that the status code is a 1xx Information response.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs2xxSuccess
fun <T> Assertion.Builder
Asserts that the status code is a 2xx Success response.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs3xxRedirection
fun <T> Assertion.Builder
Asserts that the status code is a 3xx Redirect response.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs4xxClientError
fun <T> Assertion.Builder
Asserts that the status code is a 4xx Client Error response.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs5xxServerError
fun <T> Assertion.Builder
Asserts that the status code is a 5xx Server Error response.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs
infix fun <T> Assertion.Builder
Asserts that the status code is equal to expected.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
Parameters
| Name | Description |
|---|---|
expected: Int
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
statusCodeIs
infix fun <T> Assertion.Builder
Asserts that the status code is equal to expected.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
Parameters
| Name | Description |
|---|---|
expected: HttpStatus
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
contentTypeIsCompatibleWith
infix fun <T> Assertion.Builder
Asserts that the content type of the subject is compatible with expected.
Receiver
| Name | Description |
|---|---|
Assertion.Builder
|
Parameters
| Name | Description |
|---|---|
expected: MediaType
|
ReturnValue
| Name | Description |
|---|---|
Assertion.Builder
|
Asserts that the subject is compatible with expected.
For example, a subject of
application/json;charset=UTF-8is compatiblewith the media typeapplication/json, but not with the media typeapplication/x-yaml.