osmoassert

package
v12.3.0 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConditionalError

func ConditionalError(t *testing.T, expectError bool, err error)

ConditionalError checks if expectError is true, asserts that err is an error If expectError is false, asserts that err is nil

func ConditionalPanic

func ConditionalPanic(t *testing.T, expectPanic bool, sut func())

ConditionalPanic checks if expectPanic is true, asserts that sut (system under test) panics. If expectPanic is false, asserts that sut does not panic. returns true if sut panics and false it it does not

func DecApproxEq

func DecApproxEq(t *testing.T, d1 sdk.Dec, d2 sdk.Dec, tol sdk.Dec, msgAndArgs ...interface{})

DecApproxEq is a helper function to compare two decimals. It validates the two decimal are within a certain tolerance. If not, it fails with a message.

Types

This section is empty.

Jump to

Keyboard shortcuts

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