T - The body of the response.public class ResponseEntityAssert<T> extends org.assertj.core.api.AbstractAssert<ResponseEntityAssert<T>,org.springframework.http.ResponseEntity<T>>
ResponseEntity.| Modifier and Type | Method and Description |
|---|---|
ResponseEntityAssert<T> |
hasBody(T body)
Verifies that the response contains the given object as body.
|
ResponseEntityAssert<T> |
hasStatus(org.springframework.http.HttpStatus httpStatus)
Verifies that the response has the given HTTP status code.
|
ResponseEntityAssert<T> |
isBadRequest() |
ResponseEntityAssert<T> |
isConflict() |
ResponseEntityAssert<T> |
isCreated() |
ResponseEntityAssert<T> |
isForbidden() |
ResponseEntityAssert<T> |
isInternalServerError() |
ResponseEntityAssert<T> |
isOk() |
ResponseEntityAssert<T> |
isUnauthorized() |
as, as, asList, asString, describedAs, describedAs, descriptionText, doesNotHave, doesNotHaveSameClassAs, equals, failWithMessage, getWritableAssertionInfo, has, hashCode, hasSameClassAs, hasSameHashCodeAs, hasToString, inBinary, inHexadecimal, is, isEqualTo, isExactlyInstanceOf, isIn, isIn, isInstanceOf, isInstanceOfAny, isInstanceOfSatisfying, isNot, isNotEqualTo, isNotExactlyInstanceOf, isNotIn, isNotIn, isNotInstanceOf, isNotInstanceOfAny, isNotNull, isNotOfAnyClassIn, isNotSameAs, isNull, isOfAnyClassIn, isSameAs, matches, matches, newListAssertInstance, overridingErrorMessage, satisfies, satisfies, setCustomRepresentation, throwAssertionError, usingComparator, usingComparator, usingDefaultComparator, withFailMessage, withRepresentation, withThreadDumpOnErrorpublic ResponseEntityAssert<T> hasStatus(org.springframework.http.HttpStatus httpStatus)
httpStatus - The expected HTTP status code.public ResponseEntityAssert<T> isOk()
public ResponseEntityAssert<T> isCreated()
public ResponseEntityAssert<T> isBadRequest()
public ResponseEntityAssert<T> isForbidden()
public ResponseEntityAssert<T> isInternalServerError()
public ResponseEntityAssert<T> isUnauthorized()
public ResponseEntityAssert<T> isConflict()
public ResponseEntityAssert<T> hasBody(T body)
body - The expected body.Copyright © 2018. All rights reserved.