conf

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2020 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Conf

type Conf struct {
	Echo    []string   `yaml:"echo,omitempty"`
	LogBody []LogBody  `yaml:"logBody,omitempty"`
	Replay  []Response `yaml:"replay,omitempty"`
}

Conf type to define custom request mapping

func GetConf

func GetConf(configFile string) (*Conf, error)

GetConf get the config from the given file

type LogBody

type LogBody struct {
	Path         string `yaml:"path"`
	LineLength   bool   `yaml:"lineLength"`
	ResponseCode int    `yaml:"responseCode"`
}

LogBody config type

type Response

type Response struct {
	Path        string `yaml:"path"`
	Body        string `yaml:"body,omitempty"`
	BodyFile    string `yaml:"bodyFile,omitempty"`
	ContentType string `yaml:"contentType"`
}

Response config type

Jump to

Keyboard shortcuts

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