HttpClient
HttpClient
The HTTP Methods used to make a request
The HTTP Methods used to make a request
The HTTP Request
The HTTP Request
The HTTP RequestBuilder
The HTTP RequestBuilder
The HTTP Response
The HTTP Response
Add operator support to Extractor
s these are used to generate an Assertion
using the extracted value.
Add operator support to Extractor
s these are used to generate an Assertion
using the extracted value.
GET url "http://api.rest.org/person" assert (StatusCode === Status.Ok)
The following operations are added to all Extractors
$ - extractor === expected
- the extracted value is equal to the expected
value.
$ - extractor !== expected
- the extracted value is not equal to the expected
value.
$ - extractor in (expected1, expected2, ...)
- the extracted value is in the list of expected values.
$ - extractor notIn (expected1, expected2, ...)
- the extracted value is in the list of expected values.
The following operations are added to Extractor
s that support scala.math.Ordering
.
More precisely these operations are added to Extractor[T]
if there exists an implicit
Ordering[T]
for any type T
.
$ - extractor < expected
- the extracted value is less than the expected
value.
$ - extractor <= expected
- the extracted value is less than or equal to the expected
value.
$ - extractor > expected
- the extracted value is greater than the expected
value.
$ - extractor <= expected
- the extracted value is greater than or equal to the expected
value.
Extend the default request's configuration so that partially configured requests to be reused.
Extend the default request's configuration so that partially configured requests to be reused. Foe example:
using(_ url "http://api.rest.org/person") { implicit rb => GET asserting (StatusCode === Status.OK, jsonBodyAsList[Person] === EmptyList) val id = POST body personJson asserting (StatusCode === Status.Created) returning (Header("X-Person-Id")) GET / id asserting (StatusCode === Status.OK, jsonBodyAs[Person] === Jason) }
a function to configure the default request
the current default request, implicitly resolved, defaults to the empty request