bank

package
v0.0.0-...-a9c8dba Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2024 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FilterDenomFromBalances

func FilterDenomFromBalances(
	balances []banktypes.Balance,
	denom string,
) []banktypes.Balance

func FundAccount

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

FundAccount is a test utility function that funds an account by minting the coins in the mint module, and sending them to the address account.

func FundModuleAccount

func FundModuleAccount(
	ctx sdk.Context,
	moduleName string,
	amounts sdk.Coins,
	bankKeeper bankkeeper.BaseKeeper,
) error

FundModuleAccount is a test utility function that funds a module account by minting the coins in the mint module, and sending them to the module account.

func GetModuleAccUsdcBalance

func GetModuleAccUsdcBalance(
	valAddress string,
	codec codec.Codec,
	moduleName string,
) (
	balance int64,
	err error,
)

GetModuleAccUsdcBalance is a test utility function to query USDC balance of a module account from the bank module.

func MatchUsdcOfAmount

func MatchUsdcOfAmount(amount int64) func(coins sdk.Coins) bool

MatchUsdcOfAmount is a test utility function to generate a matcher function passed into mock.MatchedBy(). This matcher can be used to match parameters of *big.Int type when setting up mocks.

Types

This section is empty.

Jump to

Keyboard shortcuts

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