Documentation ¶
Index ¶
- func HTTPTestUtil(serverF TestFunc, testFunc ExecFunc)
- func TestExit(t *testing.T, testFunc func()) int
- type ExecFunc
- type GovalinHTTP
- func (govalinHttp *GovalinHTTP) Delete(path string, deleteData ...any) string
- func (govalinHttp *GovalinHTTP) DeleteResponse(path string, deleteData ...any) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Get(path string, params ...any) string
- func (govalinHttp *GovalinHTTP) GetResponse(path string, params ...any) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Head(path string) string
- func (govalinHttp *GovalinHTTP) HeadResponse(path string) *httpclient.Response
- func (govalinHttp *GovalinHTTP) OptionResponse(path string, optionsData ...map[string]string) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Options(path string, optionsData ...map[string]string) string
- func (govalinHttp *GovalinHTTP) Patch(path string, patchData map[string]string) string
- func (govalinHttp *GovalinHTTP) PatchResponse(path string, patchData map[string]string) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Post(path string, postData any) string
- func (govalinHttp *GovalinHTTP) PostResponse(path string, postData any) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Put(path string, putData io.Reader) string
- func (govalinHttp *GovalinHTTP) PutResponse(path string, putData io.Reader) *httpclient.Response
- func (govalinHttp *GovalinHTTP) Raw() *httpclient.HttpClient
- type TestFunc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func HTTPTestUtil ¶
Types ¶
type ExecFunc ¶
type ExecFunc func(http GovalinHTTP)
type GovalinHTTP ¶
type GovalinHTTP struct { Host string // contains filtered or unexported fields }
GovalinHTTP is a simple wrapper with utility methods to simplify testing.
func (*GovalinHTTP) Delete ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) Delete(path string, deleteData ...any) string
func (*GovalinHTTP) DeleteResponse ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) DeleteResponse(path string, deleteData ...any) *httpclient.Response
func (*GovalinHTTP) GetResponse ¶
func (govalinHttp *GovalinHTTP) GetResponse(path string, params ...any) *httpclient.Response
func (*GovalinHTTP) Head ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) Head(path string) string
func (*GovalinHTTP) HeadResponse ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) HeadResponse(path string) *httpclient.Response
func (*GovalinHTTP) OptionResponse ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) OptionResponse(path string, optionsData ...map[string]string) *httpclient.Response
func (*GovalinHTTP) Options ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) Options(path string, optionsData ...map[string]string) string
func (*GovalinHTTP) Patch ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) Patch(path string, patchData map[string]string) string
func (*GovalinHTTP) PatchResponse ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) PatchResponse(path string, patchData map[string]string) *httpclient.Response
func (*GovalinHTTP) PostResponse ¶
func (govalinHttp *GovalinHTTP) PostResponse(path string, postData any) *httpclient.Response
func (*GovalinHTTP) Put ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) Put(path string, putData io.Reader) string
func (*GovalinHTTP) PutResponse ¶ added in v0.0.6
func (govalinHttp *GovalinHTTP) PutResponse(path string, putData io.Reader) *httpclient.Response
func (*GovalinHTTP) Raw ¶
func (govalinHttp *GovalinHTTP) Raw() *httpclient.HttpClient
Click to show internal directories.
Click to hide internal directories.