apptest

package
v0.0.0-...-1535236 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type Response

type Response struct {
	RawResponse *httptest.ResponseRecorder
	// contains filtered or unexported fields
}

func (*Response) Body

func (r *Response) Body() string

func (*Response) Code

func (r *Response) Code() int

func (*Response) Header

func (r *Response) Header() http.Header

func (*Response) IsOK

func (r *Response) IsOK() bool

func (*Response) IsRedirect

func (r *Response) IsRedirect() bool

type Session

type Session struct {
	CookieJar http.CookieJar
	// contains filtered or unexported fields
}

Represents a request, or requests to a given medium application.

func New

func New(medium http.Handler) *Session

func (*Session) FollowRedirect

func (ar *Session) FollowRedirect(res *Response) *Response

func (*Session) Get

func (ar *Session) Get(route string, headers http.Header) *Response

func (*Session) PostForm

func (ar *Session) PostForm(route string, headers http.Header, formValues url.Values) *Response

Jump to

Keyboard shortcuts

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