Documentation ¶
Index ¶
- func AdvancePort(p *uint32) uint32
- func AdvancePortSafe(p *uint32, errIfPortInUse func(proposedPort uint32) error, ...) (uint32, error)
- func AdvancePortSafeListen(p *uint32, retryOptions ...retry.Option) uint32
- func GetParallelProcessCount() int
- func GetPortOffset() int
- func MustAdvancePortSafe(p *uint32, errIfPortInUse func(proposedPort uint32) error, ...) uint32
- func RetryWithLoggedError() retry.Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AdvancePort ¶ added in v1.15.0
AdvancePort advances the provided port by 1, and adds an offset to support running tests in parallel
func AdvancePortSafe ¶ added in v1.15.0
func AdvancePortSafe(p *uint32, errIfPortInUse func(proposedPort uint32) error, retryOptions ...retry.Option) (uint32, error)
AdvancePortSafe advances the provided port by 1 until it returns a port that is safe to use The availability of the port is determined by the errIfPortInUse function
func AdvancePortSafeListen ¶ added in v1.15.0
AdvancePortSafeListen returns a port that is safe to use in parallel tests It relies on pinging the port to see if it is in use
func GetParallelProcessCount ¶
func GetParallelProcessCount() int
GetParallelProcessCount returns the parallel process number for the current ginkgo process
func GetPortOffset ¶
func GetPortOffset() int
GetPortOffset returns the number of parallel Ginkgo processes * 1000 This is intended to be used by tests which need to produce unique ports so that they can be run in parallel without port conflict
func MustAdvancePortSafe ¶ added in v1.17.0
func MustAdvancePortSafe(p *uint32, errIfPortInUse func(proposedPort uint32) error, retryOptions ...retry.Option) uint32
MustAdvancePortSafe executes AdvancePortSafe and panics if an error is returned
func RetryWithLoggedError ¶ added in v1.18.0
func RetryWithLoggedError() retry.Option
RetryWithLoggedError retries if there is an error and prints that error to stdout
Types ¶
This section is empty.