assert

package
v0.0.0-...-3a05015 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ArrayEquals

func ArrayEquals[T constraints.Ordered](t *testing.T, expected, actual []T)

ArrayEquals tests whether two slices are equal as determined by their having identical lengths and, once sorted, identical elements at each index.

func Contains

func Contains[T comparable](t *testing.T, arr []T, val T)

Contains asserts that a given array contains an expected value.

func Equals

func Equals[T comparable](t *testing.T, expected, actual T)

Equals tests whether two comparable values are equal.

func MapEquals

func MapEquals[M ~map[K]V, K, V comparable](t *testing.T, expected, actual M)

MapEquals tests whether two maps of comparable types are equal as determined by their having equal lengths, identical key sets, and identical values for each key in those sets.

func NotEquals

func NotEquals[T comparable](t *testing.T, expected, actual T)

Equals tests whether two comparable values are not equal.

Types

This section is empty.

Jump to

Keyboard shortcuts

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