test

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: May 23, 2022 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertErrIsProblem

func AssertErrIsProblem(t *testing.T, err error) bool

AssertErrIsProblem asserts err is a *problem.Problem

func AssertErrProblemDetail

func AssertErrProblemDetail(t *testing.T, detail string, err error) bool

AssertErrProblemDetail asserts err is a *problem.Problem with the specified detail

func AssertErrProblemStatusCode

func AssertErrProblemStatusCode(t *testing.T, code int, err error) bool

AssertErrProblemStatusCode asserts err is a *problem.Problem with the specified status code

func AssertErrProblemTitle

func AssertErrProblemTitle(t *testing.T, title string, err error) bool

AssertErrProblemTitle asserts err is a *problem.Problem with the specified title

func Contains

func Contains(needle string) gomock.Matcher

func FreeTCPPort

func FreeTCPPort() (port int)

FreeTCPPort asks the kernel for a free open port that is ready to use. Taken from https://gist.github.com/sevkin/96bdae9274465b2d09191384f86ef39d

func GetIntegrationTestConfig

func GetIntegrationTestConfig(testDirectory string) map[string]string

func WaitFor

func WaitFor(t *testing.T, p Predicate, timeout time.Duration, message string, msgArgs ...interface{}) bool

func WaitForNoFail

func WaitForNoFail(t *testing.T, p Predicate, timeout time.Duration) bool

Types

type Predicate

type Predicate func() (bool, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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