httptest

package
v0.12.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 27, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FakeClient

type FakeClient struct {
	Requests []http.Request
	Response http.Response
	Err      error
	// contains filtered or unexported fields
}

func NewFakeClient

func NewFakeClient() *FakeClient

func (*FakeClient) Do

func (fc *FakeClient) Do(req *http.Request) (*http.Response, error)

func (*FakeClient) RequestURLs added in v0.10.7

func (fc *FakeClient) RequestURLs() []string

func (*FakeClient) SetResponse added in v0.10.7

func (fc *FakeClient) SetResponse(s string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL