Documentation ¶
Index ¶
- func ExpandHomeDir(path string) (string, error)
- func NewTestBufferHandlerFunc(method string, requestBuffer io.Writer, responseHeader int, ...) http.Handler
- func ParseJsonFromFile(filePath string, tolerateEmptyInput bool) (map[string]interface{}, error)
- func ParseJsonFromFileOrStdin(filePath string, tolerateEmptyStdin bool) (map[string]interface{}, error)
- func ReadArgsOrStdin(args []string) (string, error)
- func TestGateMuxWithVersionHandler() *http.ServeMux
- func TestPrettyJsonDiff(t *testing.T, description, expected string, recieved []byte)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExpandHomeDir ¶ added in v1.21.1
ExpandHomeDir expands filepath with a tilde prefix. If the given filepath doesn't have a tilde this function return the filepath as it is.
func NewTestBufferHandlerFunc ¶ added in v1.21.1
func NewTestBufferHandlerFunc(method string, requestBuffer io.Writer, responseHeader int, responseBody string) http.Handler
NewTestBufferHandlerFunc returns an http.Handler which buffers the request body, writes the response header, and writes the response body. Requests that do not match the specified method recieve 404 Not Found.
func ParseJsonFromFile ¶ added in v1.21.1
func ParseJsonFromFileOrStdin ¶ added in v0.4.0
func ReadArgsOrStdin ¶ added in v1.21.1
func TestGateMuxWithVersionHandler ¶ added in v1.21.1
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.