helpers

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertActual

func AssertActual(a actualAssertion, actual interface{}, msgAndArgs ...interface{}) error

assertActual is a helper function to allow the step function to call assertion functions where you want to compare an actual value to a predefined state like nil, empty or true/false.

func AssertExpectedAndActual

func AssertExpectedAndActual(a ExpectedAndActualAssertion, expected, actual interface{}, msgAndArgs ...interface{}) error

assertExpectedAndActual is a helper function to allow the step function to call assertion functions where you want to compare an expected and an actual value.

func FormatError

func FormatError(status *rpc.Status) error

Types

type Asserter

type Asserter struct {
	// contains filtered or unexported fields
}

asserter is used to be able to retrieve the error reported by the called assertion

func (*Asserter) Errorf

func (a *Asserter) Errorf(format string, args ...interface{})

Errorf is used by the called assertion to report an error

type ExpectedAndActualAssertion

type ExpectedAndActualAssertion func(t assert.TestingT, expected, actual interface{}, msgAndArgs ...interface{}) bool

Jump to

Keyboard shortcuts

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