mocks

package
v0.0.0-...-76817a0 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2015 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BeCreated

func BeCreated() *BaseMatcher

BeCreated matcher

func BeRunning

func BeRunning() *BaseMatcher

BeRunning matcher

func BindedWith

func BindedWith(expected map[string]string) *BaseMatcher

BindedWith matcher

func Handle

func Handle(method string) *handleMatcher

Handle route matcher

func HaveHeader

func HaveHeader(name string) *haveHeaderMatcher

HaveHeader matcher

Types

type EngineMock

type EngineMock struct {
	// contains filtered or unexported fields
}

func (*EngineMock) DELETE

func (e *EngineMock) DELETE(relativePath string, handlers ...gin.HandlerFunc)

func (*EngineMock) FmtRoutes

func (e *EngineMock) FmtRoutes() (s string)

func (*EngineMock) GET

func (e *EngineMock) GET(relativePath string, handlers ...gin.HandlerFunc)

func (*EngineMock) IsRunning

func (e *EngineMock) IsRunning() bool

func (*EngineMock) POST

func (e *EngineMock) POST(relativePath string, handlers ...gin.HandlerFunc)

func (*EngineMock) PUT

func (e *EngineMock) PUT(relativePath string, handlers ...gin.HandlerFunc)

func (*EngineMock) Port

func (e *EngineMock) Port() string

func (*EngineMock) Routes

func (e *EngineMock) Routes() []string

func (*EngineMock) Run

func (e *EngineMock) Run(port string) error

func (*EngineMock) String

func (e *EngineMock) String() string

type ResourceMock

type ResourceMock struct {
	// contains filtered or unexported fields
}

func Resource

func Resource() *ResourceMock

func (*ResourceMock) Form

func (r *ResourceMock) Form() interface{}

func (*ResourceMock) IsBindedWith

func (r *ResourceMock) IsBindedWith(m map[string]string) (ok bool)

func (*ResourceMock) IsCreated

func (r *ResourceMock) IsCreated() bool

func (*ResourceMock) Save

func (r *ResourceMock) Save() (ok bool)

func (*ResourceMock) String

func (r *ResourceMock) String() string

func (*ResourceMock) Url

func (r *ResourceMock) Url() string

Jump to

Keyboard shortcuts

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