testassert

package
v1.9.1 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Contains

func Contains(t *testing.T, s, contains any, msgAndArgs ...any) bool

Contains fails the test if s does not contain contains.

func Equal

func Equal(t *testing.T, expected, actual any, msgAndArgs ...any) bool

Equal fails the test if expected and actual are not deeply equal.

func False

func False(t *testing.T, value bool, msgAndArgs ...any) bool

False fails the test if value is true.

func JSONEq

func JSONEq(t *testing.T, expected, actual string, msgAndArgs ...any) bool

JSONEq fails the test if expected and actual are not equivalent JSON values.

func Nil

func Nil(t *testing.T, v any, msgAndArgs ...any) bool

Nil fails the test if v is not nil.

func NoError

func NoError(t *testing.T, err error, msgAndArgs ...any) bool

NoError fails the test if err is non-nil.

func NotContains

func NotContains(t *testing.T, s, contains any, msgAndArgs ...any) bool

NotContains fails the test if s contains contains.

func True

func True(t *testing.T, value bool, msgAndArgs ...any) bool

True fails the test if value is false.

Types

This section is empty.

Jump to

Keyboard shortcuts

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