test

package
v1.7.1 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2021 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 8 more Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExpectError

func ExpectError(t *testing.T, err error, substr string)

ExpectError calls t.Fatalf if the error does not contain a substr match. If substr is empty, a nil error is expected. It is useful to call ExpectError from subtests.

func SkipRest

func SkipRest(t *testing.T, desc string, err error, contains string) bool

SkipRest returns true if there was a non-nil error or if we expected an error that didn't happen, and logs the appropriate error on the test object. The return value indicates whether we should skip the rest of the test case due to the error result.

Types

This section is empty.

Jump to

Keyboard shortcuts

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