Class HttpRequestResult

java.lang.Object
com.soklet.HttpRequestResult

@ThreadSafe public final class HttpRequestResult extends Object
Encapsulates the results of a request that would normally be handled by your HttpServer (both logical response and bytes to be sent over the wire), used for integration testing via Simulator.performHttpRequest(Request).

Instances can be acquired via the withMarshaledResponse(MarshaledResponse) builder factory method. A convenience instance factory is also available via fromMarshaledResponse(MarshaledResponse).

The Server-Sent Event equivalent of this type is SseRequestResult, which is used for integration testing via Simulator.performSseRequest(Request).

See https://www.soklet.com/docs/testing#integration-testing for detailed documentation.

Author:
Mark Allen