import "github.com/gobuffalo/httptest"
Package httptest was formerly known as [https://github.com/markbates/willie](https://github.com/markbates/willie). It is used to test HTTP applications easily.
file.go httptest.go json.go request.go response.go version.go xml.go
const DefaultRemoteAddr = httptest.DefaultRemoteAddr
map the std httptest package for ease
const Version = "v1.1.0"
var NewRecorder = httptest.NewRecorder
var NewRequest = httptest.NewRequest
var NewTLSServer = httptest.NewTLSServer
var NewUnstartedServer = httptest.NewUnstartedServer
type JSON struct { URL string Headers map[string]string Username string Password string // contains filtered or unexported fields }
func (r *JSON) Delete() *JSONResponse
func (r *JSON) Get() *JSONResponse
func (r *JSON) Patch(body interface{}) *JSONResponse
func (r *JSON) Post(body interface{}) *JSONResponse
func (r *JSON) Put(body interface{}) *JSONResponse
func (r *JSONResponse) Bind(x interface{})
type Request struct { URL string Headers map[string]string Username string Password string // contains filtered or unexported fields }
type Response struct { *httptest.ResponseRecorder }
type ResponseRecorder = httptest.ResponseRecorder
func (r *XML) Delete() *XMLResponse
func (r *XML) Get() *XMLResponse
func (r *XML) Patch(body interface{}) *XMLResponse
func (r *XML) Post(body interface{}) *XMLResponse
func (r *XML) Put(body interface{}) *XMLResponse
func (r *XMLResponse) Bind(x interface{})
Path | Synopsis |
---|---|
packrd | You can use the "packr2 clean" command to clean up this, and any other packr generated files. |
Package httptest imports 14 packages (graph) and is imported by 1 packages. Updated 2019-02-09. Refresh now. Tools for package owners.