Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MockServer ¶
Types ¶
type DefaultRESTClient ¶
type DefaultRESTClient struct{}
func (*DefaultRESTClient) Do ¶ added in v0.7.0
func (c *DefaultRESTClient) Do(request *Request) (*http.Response, error)
func (*DefaultRESTClient) RetrieveBody ¶
func (c *DefaultRESTClient) RetrieveBody(request *Request) ([]byte, error)
func (*DefaultRESTClient) RetrieveHead ¶ added in v0.6.0
func (c *DefaultRESTClient) RetrieveHead(url string) (*http.Response, error)
type MockReadCloser ¶ added in v0.6.0
type MockReadCloser struct { ReadBody []byte CloseError error // contains filtered or unexported fields }
func (*MockReadCloser) Close ¶ added in v0.6.0
func (mrc *MockReadCloser) Close() error
type MockReader ¶ added in v0.3.0
type MockReader struct{}
type RESTClient ¶
type TestRESTClient ¶
type TestRESTClient struct { Body []byte Error error StatusCode int DoRequests []*Request Requests []*Request HeadRequests []*string HeadResponse *http.Response }
func (*TestRESTClient) Do ¶ added in v0.7.0
func (c *TestRESTClient) Do(request *Request) (*http.Response, error)
func (*TestRESTClient) RetrieveBody ¶
func (c *TestRESTClient) RetrieveBody(request *Request) ([]byte, error)
func (*TestRESTClient) RetrieveHead ¶ added in v0.6.0
func (c *TestRESTClient) RetrieveHead(url string) (*http.Response, error)
Click to show internal directories.
Click to hide internal directories.