Versions in this module Expand all Collapse all v0 v0.1.0 Jul 24, 2024 Changes in this version + type Body struct + Base64Bytes string + ContentType string + Not bool + Type BodyType + func JsonBody(value string) Body + func StringBody(value string) Body + type BodyType string + const BINARY + const JSON + const JSONPath + const JSONSchema + const LogEvent + const Parameters + const Regex + const String + const XML + const XMLSchema + const XPath + type ConnectionOptions struct + ChunkSize int + CloseSocket bool + CloseSocketDelay TimeUnit + ContentLengthHeaderOverride int + KeepAliveOverride bool + SuppressConnectionHeader bool + SuppressContentLengthHeader bool + type Expectation struct + HTTPError HTTPError + HTTPForward HTTPForward + HTTPForwardClassCallback HTTPForwardClassCallback + HTTPForwardObjectCallback HTTPForwardObjectCallback + HTTPForwardTemplate HTTPForwardTemplate + HTTPOverrideForwardedRequest HTTPOverrideForwardedRequest + HTTPResponseClassCallback HTTPResponseClassCallback + HTTPResponseObjectCallback HTTPResponseObjectCallback + HTTPResponseTemplate HTTPResponseTemplate + ID string + Priority int + Request Request + Response Response + TimeToLive TimeToLive + Times Times + type ExpectationId struct + ID string + type HTTPCookie struct + Name string + Value string + type HTTPCookies struct + Add []HTTPCookie + Remove []string + Replace []HTTPCookie + type HTTPError struct + Delay TimeUnit + DropConnection bool + ResponseBytes string + type HTTPForward struct + Delay TimeUnit + Host string + Port int + Scheme string + type HTTPForwardClassCallback struct + CallbackClass string + Delay TimeUnit + type HTTPForwardObjectCallback struct + ClientID string + Delay TimeUnit + ResponseCallback bool + type HTTPForwardTemplate struct + Delay TimeUnit + Template string + TemplateType string + type HTTPHeader struct + Name string + Values []string + type HTTPHeaders struct + Add []HTTPHeader + Remove []string + Replace []HTTPHeader + type HTTPOverrideForwardedRequest struct + Delay TimeUnit + RequestModifier RequestModifier + RequestOverride Request + ResponseModifier ResponseModifier + ResponseOverride Response + type HTTPResponseClassCallback struct + CallbackClass string + Delay TimeUnit + type HTTPResponseObjectCallback struct + ClientID string + Delay TimeUnit + ResponseCallback bool + type HTTPResponseTemplate struct + Delay TimeUnit + Template string + TemplateType string + type MockServerClient struct + func New(uri string) *MockServerClient + func (msc *MockServerClient) Clear(request Request) + func (msc *MockServerClient) ClearAll() + func (msc *MockServerClient) ClearById(expectationId string) + func (msc *MockServerClient) RegisterExpectation(expectation Expectation) + func (msc *MockServerClient) Verify(verify Verify) + func (msc *MockServerClient) VerifySequence(sequence VerifySequence) + type PathModifier struct + Regex string + Substitution string + type PathParameter struct + Name string + Values []string + type QueryParameter struct + Name string + Values []string + func WithQueryParameter(name string, values ...string) []QueryParameter + type QueryStringParameters struct + Add []QueryParameter + Remove []string + Replace []QueryParameter + type Request struct + Body Body + Cookies []HTTPCookie + Headers []HTTPHeader + KeepAlive bool + Method string + Path string + PathParameters []PathParameter + Protocol string + QueryStringParameters []QueryParameter + Secure bool + SocketAddress SocketAddress + func (r *Request) WithPath(path string) *Request + type RequestModifier struct + Cookies HTTPCookies + Headers HTTPHeaders + Path PathModifier + QueryStringParameters QueryStringParameters + type Response struct + Body Body + ConnectionOptions ConnectionOptions + Cookies []HTTPCookie + Delay TimeUnit + Headers []HTTPHeader + ReasonPhrase string + StatusCode int + func JsonResponse(val any) Response + func StringResponse(val string) Response + type ResponseModifier struct + Cookies HTTPCookies + Headers HTTPHeaders + type SocketAddress struct + Host string + Port int + Scheme string + type TimeToLive struct + TimeToLive int + TimeUnit string + Unlimited bool + type TimeUnit struct + TimeUnit string + Value int + type Times struct + RemainingTimes int + Unlimited bool + func Once() Times + type Verify struct + ExpectationID ExpectationId + MaximumNumberOfRequestToReturnInVerificationFailure int + Request Request + Times VerifyTimes + type VerifySequence struct + ExpectationIds []ExpectationId + MaximumNumberOfRequestToReturnInVerificationFailure int + Requests []Request + func Sequence() *VerifySequence + func (vs *VerifySequence) WithIds(ids []string) *VerifySequence + type VerifyTimes struct + AtLeast int + AtMost int + func NeverCalled() VerifyTimes