prototest

package
v1.16.109 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2023 License: MPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertContainsElement

func AssertContainsElement[V any](t TestingT, list []V, element V, opts ...cmp.Option)

func AssertDeepEqual

func AssertDeepEqual(t TestingT, x, y interface{}, opts ...cmp.Option)

func AssertElementsMatch

func AssertElementsMatch[V any](
	t TestingT, listX, listY []V, opts ...cmp.Option,
)

AssertElementsMatch asserts that the specified listX(array, slice...) is equal to specified listY(array, slice...) ignoring the order of the elements. If there are duplicate elements, the number of appearances of each of them in both lists should match.

prototest.AssertElementsMatch(t, [1, 3, 2, 3], [1, 3, 3, 2])

Types

type TestingT

type TestingT interface {
	Helper()
	Fatalf(string, ...any)
}

Jump to

Keyboard shortcuts

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