aws-sdk-go: Index | Files

package eventstreamtest

import ""


Package Files

setup_server_1_10.go testing.go


var EventExceptionTypeHeader = eventstream.Header{
    Name:  eventstreamapi.MessageTypeHeader,
    Value: eventstream.StringValue(eventstreamapi.ExceptionMessageType),

EventExceptionTypeHeader is an event exception type header for specifying an event is an exeption type.

var EventMessageTypeHeader = eventstream.Header{
    Name:  eventstreamapi.MessageTypeHeader,
    Value: eventstream.StringValue(eventstreamapi.EventMessageType),

EventMessageTypeHeader is an event message type header for specifying an event is an message type.

func MarshalEventPayload Uses

func MarshalEventPayload(
    payloadMarshaler protocol.PayloadMarshaler,
    v interface{},
) []byte

MarshalEventPayload marshals a SDK API shape into its associated wire protocol payload.

func SetupEventStreamSession Uses

func SetupEventStreamSession(
    t *testing.T, handler http.Handler, h2 bool,
) (sess *session.Session, cleanupFn func(), err error)

SetupEventStreamSession creates a HTTP server SDK session for communicating with that server to be used for EventStream APIs. If HTTP/2 is enabled the server/client will only attempt to use HTTP/2.

type ServeEventStream Uses

type ServeEventStream struct {
    T      *testing.T
    Events []eventstream.Message

ServeEventStream provides serving EventStream messages from a HTTP server to the client. The events are sent sequentially to the client without delay.

func (ServeEventStream) ServeHTTP Uses

func (s ServeEventStream) ServeHTTP(w http.ResponseWriter, r *http.Request)

Package eventstreamtest imports 14 packages (graph). Updated 2019-02-22. Refresh now. Tools for package owners.