oraclematcher

package
v0.19.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2015 License: MIT, Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MatchMayChangeInTheFuture

func MatchMayChangeInTheFuture(matcher types.GomegaMatcher, value interface{}) bool

Types

type OracleMatcher

type OracleMatcher interface {
	MatchMayChangeInTheFuture(actual interface{}) bool
}

GomegaMatchers that also match the OracleMatcher interface can convey information about whether or not their result will change upon future attempts.

This allows `Eventually` and `Consistently` to short circuit if success becomes impossible.

For example, a process' exit code can never change. So, gexec's Exit matcher returns `true` for `MatchMayChangeInTheFuture` until the process exits, at which point it returns `false` forevermore.

Jump to

Keyboard shortcuts

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