test

package
v2.16.0 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Completes

func Completes(t *testing.T, duration time.Duration, f func(), args ...interface{})

Completes executes f (in a goroutine), and blocks until either f returns, or the provided duration has elapsed. In the latter case, calls t.Errorf to fail the test. Provide optional format string and arguments to add context to the test error message.

func Panics added in v2.16.0

func Panics(t *testing.T, f func(), target error) (result bool)

Panics returns true iff calling f panics with an error and either target is nil or errors.Is(error, target) is true.

Types

This section is empty.

Jump to

Keyboard shortcuts

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