test

package
v0.0.0-...-045286d Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertErrorMatch

func AssertErrorMatch(t *testing.T, s string, e error)

AssertErrorMatch will fail if the error doesn't match the provided error.

func AssertNoError

func AssertNoError(t *testing.T, err error)

AssertNoError will fail if the provided err value is an error.

func MatchErrorString

func MatchErrorString(t *testing.T, s string, e error) bool

MatchErrorString takes a string and matches on the error and returns true if the string matches the error.

This is useful in table tests.

If the string can't be compiled as an regexp, then this will fail with a Fatal error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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