mock

package module
v1.1.16 Latest Latest
Warning

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

Go to latest
Published: May 19, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IEndpoint

type IEndpoint interface {
	RequestHandler(handler func(string, string, string)) IEndpoint
	Reply(handler func(IReply)) IEndpoint
}

IEndpoint interface

type IReply

type IReply interface {
	Body(body interface{}, logger log.ILog) IReply
	Content(content string) IReply
	Code(code int) IReply
	Header(key, value string) IReply
	BodyString(body string) IReply
	Delay(delayTime int) IReply
}

IReply interface

type IServer

type IServer interface {
	Endpoint(name string, method string, path string) IEndpoint
}

IServer interface

func CreateServer

func CreateServer(name string, log log.ILog) IServer

CreateServer creates the server

type ISystem

type ISystem interface {
	End()
}

ISystem interface

func StartSystem

func StartSystem(path, composeFile string, services map[string]dockerCompose.Service, mocked []IServer, log log.ILog, systemLogs bool) (ISystem, error)

StartSystem starts the mock system

Jump to

Keyboard shortcuts

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