Documentation ¶
Index ¶
- func AssertOriginCall(m *gno.Machine)
- func IsOriginCall(m *gno.Machine) bool
- func TestSkipHeights(m *gno.Machine, count int64)
- func X_callerAt(m *gno.Machine, n int) string
- func X_getRealm(m *gno.Machine, height int) (address string, pkgPath string)
- func X_isRealm(m *gno.Machine, pkgPath string) bool
- func X_testIssueCoins(m *gno.Machine, addr string, denom []string, amt []int64)
- func X_testSetOrigCaller(m *gno.Machine, addr string)
- func X_testSetOrigPkgAddr(m *gno.Machine, addr string)
- func X_testSetOrigSend(m *gno.Machine, sentDenom []string, sentAmt []int64, spentDenom []string, ...)
- func X_testSetRealm(m *gno.Machine, addr, pkgPath string)
- type RealmOverride
- type TestBanker
- func (tb *TestBanker) GetCoins(addr crypto.Bech32Address) (dst tm2std.Coins)
- func (tb *TestBanker) IssueCoin(addr crypto.Bech32Address, denom string, amt int64)
- func (tb *TestBanker) RemoveCoin(addr crypto.Bech32Address, denom string, amt int64)
- func (tb *TestBanker) SendCoins(from, to crypto.Bech32Address, amt tm2std.Coins)
- func (tb *TestBanker) TotalCoin(denom string) int64
- type TestExecContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertOriginCall ¶
func IsOriginCall ¶
func TestSkipHeights ¶
func X_testIssueCoins ¶
func X_testSetOrigCaller ¶
func X_testSetOrigPkgAddr ¶
func X_testSetOrigSend ¶
func X_testSetRealm ¶
Types ¶
type RealmOverride ¶
type RealmOverride struct { Addr crypto.Bech32Address PkgPath string }
type TestBanker ¶
type TestBanker struct {
CoinTable map[crypto.Bech32Address]tm2std.Coins
}
TestBanker is a banker that can be used as a mock banker in test contexts.
func (*TestBanker) GetCoins ¶
func (tb *TestBanker) GetCoins(addr crypto.Bech32Address) (dst tm2std.Coins)
GetCoins implements the Banker interface.
func (*TestBanker) IssueCoin ¶
func (tb *TestBanker) IssueCoin(addr crypto.Bech32Address, denom string, amt int64)
IssueCoin implements the Banker interface.
func (*TestBanker) RemoveCoin ¶
func (tb *TestBanker) RemoveCoin(addr crypto.Bech32Address, denom string, amt int64)
RemoveCoin implements the Banker interface.
func (*TestBanker) SendCoins ¶
func (tb *TestBanker) SendCoins(from, to crypto.Bech32Address, amt tm2std.Coins)
SendCoins implements the Banker interface.
func (*TestBanker) TotalCoin ¶
func (tb *TestBanker) TotalCoin(denom string) int64
TotalCoin implements the Banker interface.
type TestExecContext ¶
type TestExecContext struct { std.ExecContext // These are used to set up the result of CurrentRealm() and PrevRealm(). RealmFrames map[*gno.Frame]RealmOverride }
TestExecContext is the testing extension of the exec context.
Click to show internal directories.
Click to hide internal directories.