testassert

package
v14.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2021 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ContainsGrpcError

func ContainsGrpcError(t testing.TB, errs []error, err error)

ContainsGrpcError checks that an equal gRPC error is present in the slice of errors.

func GrpcEqualErr

func GrpcEqualErr(t testing.TB, expected, actual error)

GrpcEqualErr asserts that expected and actual gRPC errors are equal. This is required as comparing messages directly with `require.Equal` doesn't work.

func ProtoEqual

func ProtoEqual(t testing.TB, expected, actual interface{})

ProtoEqual asserts that expected and actual protobuf messages are equal. It can accept not only proto.Message, but slices, maps, and structs too. This is required as comparing messages directly with `require.Equal` doesn't work.

Types

This section is empty.

Jump to

Keyboard shortcuts

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