testutil

package
v1.6.3 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FundAccount

func FundAccount(bankKeeper bankkeeper.Keeper, ctx sdk.Context, addr sdk.AccAddress, amounts sdk.Coins) error

FundAccount is a utility function that funds an account by minting and sending the coins to the address. This should be used for testing purposes only!

func FundModuleAccount

func FundModuleAccount(bankKeeper bankkeeper.Keeper, ctx sdk.Context, recipientMod string, amounts sdk.Coins) error

FundModuleAccount is a utility function that funds a module account by minting and sending the coins to the address. This should be used for testing purposes only!

Types

type MockTransferKeeper added in v1.6.0

type MockTransferKeeper struct {
	mock.Mock
	bankkeeper.Keeper
	Sequences map[string]uint64
}

MockTransferKeeper defines a mocked object that implements the TransferKeeper interface. It's used on tests to abstract the complexity of IBC transfers. NOTE: Bank keeper logic is not mocked since we want to test that balance has been updated for sender and recipient.

func (*MockTransferKeeper) GetDenomTrace added in v1.6.0

func (m *MockTransferKeeper) GetDenomTrace(ctx sdk.Context, denomTraceHash tmbytes.HexBytes) (transfertypes.DenomTrace, bool)

func (*MockTransferKeeper) SendTransfer added in v1.6.0

func (m *MockTransferKeeper) SendTransfer(
	ctx sdk.Context,
	sourcePort,
	sourceChannel string,
	token sdk.Coin,
	sender sdk.AccAddress,
	receiver string,
	timeoutHeight clienttypes.Height,
	timeoutTimestamp uint64,
) error

func (*MockTransferKeeper) Transfer added in v1.6.0

Transfer implements types.IBCTransferKeeper.

Directories

Path Synopsis
Package network implements and exposes a fully operational in-process Tendermint test network that consists of at least one or potentially many validators.
Package network implements and exposes a fully operational in-process Tendermint test network that consists of at least one or potentially many validators.

Jump to

Keyboard shortcuts

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