Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Interceptor ¶ added in v0.3.5
type Interceptor struct {
// contains filtered or unexported fields
}
func NewInterceptor ¶ added in v0.3.5
func NewInterceptor(core http.RoundTripper) *Interceptor
NewInterceptor constructs and returns the pointer to Interceptor. Interceptor is used to intercept every http client calls and store their responses into keploy context.
func (Interceptor) RoundTrip ¶ added in v0.3.5
RoundTrip is the custom method which is called before making http client calls to capture or replay the outputs of external http service.
func (*Interceptor) SetContext ¶ added in v0.3.5
func (i *Interceptor) SetContext(requestContext context.Context)
SetContext is used to store the keploy context from request context into the Interceptor kctx field.
type ReadCloser ¶
type ReadCloser struct { *bytes.Reader Body io.ReadCloser }
ReadCloser is used so that gob could encode-decode http.Response.
func (ReadCloser) Close ¶
func (rc ReadCloser) Close() error
func (*ReadCloser) MarshalBinary ¶
func (rc *ReadCloser) MarshalBinary() ([]byte, error)
func (*ReadCloser) UnmarshalBinary ¶
func (rc *ReadCloser) UnmarshalBinary(b []byte) error
Click to show internal directories.
Click to hide internal directories.