Documentation ¶
Index ¶
- func AccAddressFromBech32(address string) (addr sdk.AccAddress, err error)
- func AddHelperModuleAccountAddr(moduleAccAddrs map[string]bool) map[string]bool
- func AddHelperModuleAccountPermissions(maccPerms map[string][]string) map[string][]string
- func CheckInvariant(t require.TestingT, ctx sdk.Context, invariant sdk.Invariant, failed bool, ...)
- func ConvertAddrsToValAddrs(addrs []sdk.AccAddress) []sdk.ValAddress
- func CreateAccounts(accNum int, valAccNum int) (acountsAddresses []sdk.AccAddress, validatorsAddresses []sdk.ValAddress)
- func CreateIncrementalAccounts(accNum int, genInitNumber int) []sdk.AccAddress
- func CreateRandomAccAddress() string
- func CreateRandomAccAddressHexAndBechNoBalance(i int64) (hex string, bech string)
- func CreateTestPubKeys(numPubKeys int) []cryptotypes.PubKey
- func NewPubKeyFromHex(pk string) (res cryptotypes.PubKey)
- func TestAddr(addr string, bech string) (sdk.AccAddress, error)
- func ValidateManyInvariants(t require.TestingT, ctx sdk.Context, invariants []sdk.Invariant)
- type AuthUtils
- func (au *AuthUtils) CreateBaseAccount(ctx sdk.Context, address string, coin sdk.Coins) error
- func (au *AuthUtils) CreateDefaultDenomBaseAccount(ctx sdk.Context, address string, amount math.Int) error
- func (au *AuthUtils) CreateDefaultDenomVestingAccount(ctx sdk.Context, address string, amount math.Int, start time.Time, ...) error
- func (au *AuthUtils) CreateVestingAccount(ctx sdk.Context, address string, coins sdk.Coins, start time.Time, ...) error
- func (au *AuthUtils) ModifyVestingAccountOriginalVesting(ctx sdk.Context, address string, newOrignalVestings sdk.Coins) error
- func (au *AuthUtils) VerifyAccountDoesNotExist(ctx sdk.Context, address sdk.AccAddress)
- func (au *AuthUtils) VerifyDefaultDenomVestingAccount(ctx sdk.Context, address sdk.AccAddress, lockedAmount math.Int, ...)
- func (au *AuthUtils) VerifyIsContinuousVestingAccount(ctx sdk.Context, address sdk.AccAddress)
- func (au *AuthUtils) VerifyVestingAccount(ctx sdk.Context, address sdk.AccAddress, lockedAmount sdk.Coins, ...)
- type BankUtils
- func (bu *BankUtils) AddCoinsToAccount(ctx sdk.Context, coinsToMint sdk.Coins, toAddr sdk.AccAddress)
- func (bu *BankUtils) AddCoinsToModule(ctx sdk.Context, coinsToMint sdk.Coin, moduleName string)
- func (bu *BankUtils) AddDefaultDenomCoinsToAccount(ctx sdk.Context, amount math.Int, toAddr sdk.AccAddress) (denom string)
- func (bu *BankUtils) AddDefaultDenomCoinsToModule(ctx sdk.Context, amount math.Int, moduleName string) (denom string)
- func (bu *BankUtils) DisableSend(ctx sdk.Context)
- func (bu *BankUtils) GetAccountAllBalances(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins
- func (bu *BankUtils) GetAccountBalanceByDenom(ctx sdk.Context, addr sdk.AccAddress, denom string) math.Int
- func (bu *BankUtils) GetAccountDefultDenomBalance(ctx sdk.Context, addr sdk.AccAddress) math.Int
- func (bu *BankUtils) GetAccountLockedCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins
- func (bu *BankUtils) GetModuleAccountAllBalances(ctx sdk.Context, accName string) sdk.Coins
- func (bu *BankUtils) GetModuleAccountBalanceByDenom(ctx sdk.Context, accName string, denom string) math.Int
- func (bu *BankUtils) GetModuleAccountDefultDenomBalance(ctx sdk.Context, accName string) math.Int
- func (bu *BankUtils) GetTotalSupplyByDenom(ctx sdk.Context, denom string) sdk.Coin
- func (bu *BankUtils) VerifyAccountAllBalances(ctx sdk.Context, addr sdk.AccAddress, expectedBalances sdk.Coins)
- func (bu *BankUtils) VerifyAccountBalanceByDenom(ctx sdk.Context, addr sdk.AccAddress, denom string, expectedAmount math.Int)
- func (bu *BankUtils) VerifyAccountBalances(ctx sdk.Context, addr sdk.AccAddress, expectedBalances sdk.Coins, ...)
- func (bu *BankUtils) VerifyAccountDefaultDenomBalance(ctx sdk.Context, addr sdk.AccAddress, expectedAmount math.Int)
- func (bu *BankUtils) VerifyAccountDefultDenomLocked(ctx sdk.Context, addr sdk.AccAddress, expectedAmount math.Int)
- func (bu *BankUtils) VerifyAccountDefultDenomSpendableCoins(ctx sdk.Context, addr sdk.AccAddress, expectedAmount math.Int)
- func (bu *BankUtils) VerifyAccountLockedByDenom(ctx sdk.Context, addr sdk.AccAddress, denom string, expectedAmount math.Int)
- func (bu *BankUtils) VerifyAccountSpendableByDenom(ctx sdk.Context, addr sdk.AccAddress, denom string, expectedAmount math.Int)
- func (bu *BankUtils) VerifyDefultDenomTotalSupply(ctx sdk.Context, expectedAmount math.Int)
- func (bu *BankUtils) VerifyLockedCoins(ctx sdk.Context, addr sdk.AccAddress, expectedLockedCoins sdk.Coins, ...)
- func (bu *BankUtils) VerifyModuleAccountAllBalances(ctx sdk.Context, accName string, expectedAmount sdk.Coins)
- func (bu *BankUtils) VerifyModuleAccountBalanceByDenom(ctx sdk.Context, accName string, denom string, expectedAmount math.Int)
- func (bu *BankUtils) VerifyModuleAccountDefultDenomBalance(ctx sdk.Context, accName string, expectedAmount math.Int)
- func (bu *BankUtils) VerifyTotalSupply(ctx sdk.Context, expectedAmount sdk.Coins)
- func (bu *BankUtils) VerifyTotalSupplyByDenom(ctx sdk.Context, denom string, expectedAmount math.Int)
- type ContextAuthUtils
- func (au *ContextAuthUtils) CreateDefaultDenomBaseAccount(address string, amount math.Int) error
- func (au *ContextAuthUtils) CreateDefaultDenomVestingAccount(address string, amount math.Int, start time.Time, end time.Time) error
- func (au *ContextAuthUtils) CreateVestingAccount(address string, coins sdk.Coins, start time.Time, end time.Time) error
- func (au *ContextAuthUtils) ModifyVestingAccountOriginalVesting(address string, newOrignalVestings sdk.Coins) error
- func (au *ContextAuthUtils) VerifyAccountDoesNotExist(address sdk.AccAddress)
- func (au *ContextAuthUtils) VerifyDefaultDenomVestingAccount(address sdk.AccAddress, lockedAmount math.Int, startTime time.Time, ...)
- func (au *ContextAuthUtils) VerifyIsContinuousVestingAccount(address sdk.AccAddress)
- func (au *ContextAuthUtils) VerifyVestingAccount(address sdk.AccAddress, lockedAmount sdk.Coins, startTime time.Time, ...)
- type ContextBankUtils
- func (bu *ContextBankUtils) AddCoinsToAccount(coinsToMint sdk.Coins, toAddr sdk.AccAddress)
- func (bu *ContextBankUtils) AddCoinsToModule(coinsToMint sdk.Coin, moduleName string)
- func (bu *ContextBankUtils) AddDefaultDenomCoinsToAccount(amount math.Int, toAddr sdk.AccAddress) (denom string)
- func (bu *ContextBankUtils) AddDefaultDenomCoinsToModule(amount math.Int, moduleName string) (denom string)
- func (bu *ContextBankUtils) DisableSend()
- func (bu *ContextBankUtils) GetAccountAllBalances(addr sdk.AccAddress) sdk.Coins
- func (bu *ContextBankUtils) GetAccountDefultDenomBalance(addr sdk.AccAddress) math.Int
- func (bu *ContextBankUtils) GetAccountLockedCoins(addr sdk.AccAddress) sdk.Coins
- func (bu *ContextBankUtils) GetModuleAccountDefultDenomBalance(accName string) math.Int
- func (bu *ContextBankUtils) VerifyAccountBalanceByDenom(addr sdk.AccAddress, denom string, expectedAmount math.Int)
- func (bu *ContextBankUtils) VerifyAccountBalances(addr sdk.AccAddress, expectedBalances sdk.Coins, isAllBalances bool)
- func (bu *ContextBankUtils) VerifyAccountDefultDenomBalance(addr sdk.AccAddress, expectedAmount math.Int)
- func (bu *ContextBankUtils) VerifyDefultDenomTotalSupply(expectedAmount math.Int)
- func (bu *ContextBankUtils) VerifyLockedCoins(addr sdk.AccAddress, expectedLockedCoins sdk.Coins, isAllLocked bool)
- func (bu *ContextBankUtils) VerifyModuleAccountBalanceByDenom(accName string, denom string, expectedAmount math.Int)
- func (bu *ContextBankUtils) VerifyModuleAccountDefultDenomBalance(accName string, expectedAmount math.Int)
- func (bu *ContextBankUtils) VerifyTotalSupplyByDenom(denom string, expectedAmount math.Int)
- type ContextDistributionUtils
- type ContextFeegrantUtils
- type ContextGovUtils
- type ContextStakingUtils
- func (su *ContextStakingUtils) CreateValidator(addr sdk.ValAddress, pk cryptotypes.PubKey, coin sdk.Coin, ...)
- func (su *ContextStakingUtils) GetStakingDenom() string
- func (su *ContextStakingUtils) GetValidator(addr sdk.ValAddress) (validator stakingtypes.Validator, found bool)
- func (su *ContextStakingUtils) GetValidators() []stakingtypes.Validator
- func (su *ContextStakingUtils) MessageDelegate(expectedCurrentAmountOfDelegations int, ...)
- func (su *ContextStakingUtils) MessageUndelegate(expectedCurrentAmountOfDelegations int, ...)
- func (su *ContextStakingUtils) SetupValidators(validators []sdk.ValAddress, delegatePerValidator math.Int)
- func (su *ContextStakingUtils) VerifyNumberOfUnbondingDelegations(expectedNumberOfUnbondingDelegations int, delegatorAddress sdk.AccAddress)
- type DistributionUtils
- type FeegrantUtils
- type GovUtils
- type StakingUtils
- func (su *StakingUtils) CreateValidator(ctx sdk.Context, addr sdk.ValAddress, pk cryptotypes.PubKey, coin sdk.Coin, ...)
- func (su *StakingUtils) GetStakingDenom(ctx sdk.Context) string
- func (su *StakingUtils) GetValidator(ctx sdk.Context, addr sdk.ValAddress) (validator stakingtypes.Validator, found bool)
- func (su *StakingUtils) GetValidators(ctx sdk.Context) []stakingtypes.Validator
- func (su *StakingUtils) MessageDelegate(ctx sdk.Context, expectedCurrentAmountOfDelegations int, ...)
- func (su *StakingUtils) MessageUndelegate(ctx sdk.Context, expectedCurrentAmountOfDelegations int, ...)
- func (su *StakingUtils) SetupValidators(ctx sdk.Context, validators []sdk.ValAddress, delegatePerValidator math.Int)
- func (su *StakingUtils) VerifyNumberOfUnbondingDelegations(ctx sdk.Context, expectedNumberOfUnbondingDelegations int, ...)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccAddressFromBech32 ¶ added in v1.2.0
func AccAddressFromBech32(address string) (addr sdk.AccAddress, err error)
AccAddressFromBech32 creates an AccAddress from a Bech32 string.
func CheckInvariant ¶
func ConvertAddrsToValAddrs ¶
func ConvertAddrsToValAddrs(addrs []sdk.AccAddress) []sdk.ValAddress
func CreateAccounts ¶
func CreateAccounts(accNum int, valAccNum int) (acountsAddresses []sdk.AccAddress, validatorsAddresses []sdk.ValAddress)
func CreateIncrementalAccounts ¶
func CreateIncrementalAccounts(accNum int, genInitNumber int) []sdk.AccAddress
func CreateRandomAccAddress ¶
func CreateRandomAccAddress() string
func CreateRandomAccAddressHexAndBechNoBalance ¶ added in v1.3.0
func CreateTestPubKeys ¶
func CreateTestPubKeys(numPubKeys int) []cryptotypes.PubKey
CreateTestPubKeys returns a total of numPubKeys public keys in ascending order.
func NewPubKeyFromHex ¶
func NewPubKeyFromHex(pk string) (res cryptotypes.PubKey)
NewPubKeyFromHex returns a PubKey from a hex string.
Types ¶
type AuthUtils ¶
type AuthUtils struct {
// contains filtered or unexported fields
}
func NewAuthUtils ¶
func NewAuthUtils(t require.TestingT, helperAccountKeeper *authkeeper.AccountKeeper, bankUtils *BankUtils) AuthUtils
func (*AuthUtils) CreateBaseAccount ¶ added in v1.2.0
func (*AuthUtils) CreateDefaultDenomBaseAccount ¶ added in v1.2.0
func (*AuthUtils) CreateDefaultDenomVestingAccount ¶
func (*AuthUtils) CreateVestingAccount ¶
func (*AuthUtils) ModifyVestingAccountOriginalVesting ¶ added in v1.2.0
func (*AuthUtils) VerifyAccountDoesNotExist ¶ added in v1.2.0
func (au *AuthUtils) VerifyAccountDoesNotExist(ctx sdk.Context, address sdk.AccAddress)
func (*AuthUtils) VerifyDefaultDenomVestingAccount ¶
func (*AuthUtils) VerifyIsContinuousVestingAccount ¶ added in v1.2.0
func (au *AuthUtils) VerifyIsContinuousVestingAccount(ctx sdk.Context, address sdk.AccAddress)
type BankUtils ¶
type BankUtils struct {
// contains filtered or unexported fields
}
func NewBankUtils ¶
func NewBankUtils(t require.TestingT, ctx sdk.Context, helperAccountKeeper *authkeeper.AccountKeeper, helperBankKeeper bankkeeper.Keeper) BankUtils
func (*BankUtils) AddCoinsToAccount ¶
func (*BankUtils) AddCoinsToModule ¶
func (*BankUtils) AddDefaultDenomCoinsToAccount ¶
func (*BankUtils) AddDefaultDenomCoinsToModule ¶
func (*BankUtils) DisableSend ¶ added in v1.2.0
func (*BankUtils) GetAccountAllBalances ¶ added in v1.2.0
func (*BankUtils) GetAccountBalanceByDenom ¶
func (*BankUtils) GetAccountDefultDenomBalance ¶
func (*BankUtils) GetAccountLockedCoins ¶ added in v1.2.0
func (*BankUtils) GetModuleAccountAllBalances ¶ added in v1.3.0
func (*BankUtils) GetModuleAccountBalanceByDenom ¶
func (*BankUtils) GetModuleAccountDefultDenomBalance ¶
func (*BankUtils) GetTotalSupplyByDenom ¶ added in v1.3.0
func (*BankUtils) VerifyAccountAllBalances ¶ added in v1.3.0
func (*BankUtils) VerifyAccountBalanceByDenom ¶
func (*BankUtils) VerifyAccountBalances ¶ added in v1.2.0
func (*BankUtils) VerifyAccountDefaultDenomBalance ¶ added in v1.3.0
func (*BankUtils) VerifyAccountDefultDenomLocked ¶ added in v1.3.0
func (*BankUtils) VerifyAccountDefultDenomSpendableCoins ¶ added in v1.3.0
func (*BankUtils) VerifyAccountLockedByDenom ¶ added in v1.3.0
func (*BankUtils) VerifyAccountSpendableByDenom ¶ added in v1.3.0
func (*BankUtils) VerifyDefultDenomTotalSupply ¶
func (*BankUtils) VerifyLockedCoins ¶ added in v1.2.0
func (*BankUtils) VerifyModuleAccountAllBalances ¶ added in v1.3.0
func (*BankUtils) VerifyModuleAccountBalanceByDenom ¶
func (*BankUtils) VerifyModuleAccountDefultDenomBalance ¶
func (*BankUtils) VerifyTotalSupply ¶ added in v1.3.0
type ContextAuthUtils ¶
type ContextAuthUtils struct { AuthUtils // contains filtered or unexported fields }
func NewContextAuthUtils ¶
func NewContextAuthUtils(t require.TestingT, testContext testenv.TestContext, helperAccountKeeper *authkeeper.AccountKeeper, bankUtils *BankUtils) *ContextAuthUtils
func (*ContextAuthUtils) CreateDefaultDenomBaseAccount ¶ added in v1.2.0
func (au *ContextAuthUtils) CreateDefaultDenomBaseAccount(address string, amount math.Int) error
func (*ContextAuthUtils) CreateDefaultDenomVestingAccount ¶
func (*ContextAuthUtils) CreateVestingAccount ¶
func (*ContextAuthUtils) ModifyVestingAccountOriginalVesting ¶ added in v1.2.0
func (au *ContextAuthUtils) ModifyVestingAccountOriginalVesting(address string, newOrignalVestings sdk.Coins) error
func (*ContextAuthUtils) VerifyAccountDoesNotExist ¶ added in v1.2.0
func (au *ContextAuthUtils) VerifyAccountDoesNotExist(address sdk.AccAddress)
func (*ContextAuthUtils) VerifyDefaultDenomVestingAccount ¶
func (au *ContextAuthUtils) VerifyDefaultDenomVestingAccount(address sdk.AccAddress, lockedAmount math.Int, startTime time.Time, endTime time.Time)
func (*ContextAuthUtils) VerifyIsContinuousVestingAccount ¶ added in v1.2.0
func (au *ContextAuthUtils) VerifyIsContinuousVestingAccount(address sdk.AccAddress)
func (*ContextAuthUtils) VerifyVestingAccount ¶
func (au *ContextAuthUtils) VerifyVestingAccount(address sdk.AccAddress, lockedAmount sdk.Coins, startTime time.Time, endTime time.Time)
type ContextBankUtils ¶
type ContextBankUtils struct { BankUtils // contains filtered or unexported fields }
func NewContextBankUtils ¶
func NewContextBankUtils(t require.TestingT, testContext testenv.TestContext, helperAccountKeeper *authkeeper.AccountKeeper, helperBankKeeper bankkeeper.Keeper) *ContextBankUtils
func (*ContextBankUtils) AddCoinsToAccount ¶
func (bu *ContextBankUtils) AddCoinsToAccount(coinsToMint sdk.Coins, toAddr sdk.AccAddress)
func (*ContextBankUtils) AddCoinsToModule ¶
func (bu *ContextBankUtils) AddCoinsToModule(coinsToMint sdk.Coin, moduleName string)
func (*ContextBankUtils) AddDefaultDenomCoinsToAccount ¶
func (bu *ContextBankUtils) AddDefaultDenomCoinsToAccount(amount math.Int, toAddr sdk.AccAddress) (denom string)
func (*ContextBankUtils) AddDefaultDenomCoinsToModule ¶
func (bu *ContextBankUtils) AddDefaultDenomCoinsToModule(amount math.Int, moduleName string) (denom string)
func (*ContextBankUtils) DisableSend ¶ added in v1.2.0
func (bu *ContextBankUtils) DisableSend()
func (*ContextBankUtils) GetAccountAllBalances ¶ added in v1.2.0
func (bu *ContextBankUtils) GetAccountAllBalances(addr sdk.AccAddress) sdk.Coins
func (*ContextBankUtils) GetAccountDefultDenomBalance ¶
func (bu *ContextBankUtils) GetAccountDefultDenomBalance(addr sdk.AccAddress) math.Int
func (*ContextBankUtils) GetAccountLockedCoins ¶ added in v1.2.0
func (bu *ContextBankUtils) GetAccountLockedCoins(addr sdk.AccAddress) sdk.Coins
func (*ContextBankUtils) GetModuleAccountDefultDenomBalance ¶
func (bu *ContextBankUtils) GetModuleAccountDefultDenomBalance(accName string) math.Int
func (*ContextBankUtils) VerifyAccountBalanceByDenom ¶
func (bu *ContextBankUtils) VerifyAccountBalanceByDenom(addr sdk.AccAddress, denom string, expectedAmount math.Int)
func (*ContextBankUtils) VerifyAccountBalances ¶ added in v1.2.0
func (bu *ContextBankUtils) VerifyAccountBalances(addr sdk.AccAddress, expectedBalances sdk.Coins, isAllBalances bool)
func (*ContextBankUtils) VerifyAccountDefultDenomBalance ¶
func (bu *ContextBankUtils) VerifyAccountDefultDenomBalance(addr sdk.AccAddress, expectedAmount math.Int)
func (*ContextBankUtils) VerifyDefultDenomTotalSupply ¶
func (bu *ContextBankUtils) VerifyDefultDenomTotalSupply(expectedAmount math.Int)
func (*ContextBankUtils) VerifyLockedCoins ¶ added in v1.2.0
func (bu *ContextBankUtils) VerifyLockedCoins(addr sdk.AccAddress, expectedLockedCoins sdk.Coins, isAllLocked bool)
func (*ContextBankUtils) VerifyModuleAccountBalanceByDenom ¶
func (bu *ContextBankUtils) VerifyModuleAccountBalanceByDenom(accName string, denom string, expectedAmount math.Int)
func (*ContextBankUtils) VerifyModuleAccountDefultDenomBalance ¶
func (bu *ContextBankUtils) VerifyModuleAccountDefultDenomBalance(accName string, expectedAmount math.Int)
func (*ContextBankUtils) VerifyTotalSupplyByDenom ¶
func (bu *ContextBankUtils) VerifyTotalSupplyByDenom(denom string, expectedAmount math.Int)
type ContextDistributionUtils ¶ added in v1.3.0
type ContextDistributionUtils struct { DistributionUtils // contains filtered or unexported fields }
func NewContextDistributionUtils ¶ added in v1.3.0
func NewContextDistributionUtils(t require.TestingT, testContext testenv.TestContext, distrKeeper *distrkeeper.Keeper) *ContextDistributionUtils
type ContextFeegrantUtils ¶ added in v1.3.0
type ContextFeegrantUtils struct { FeegrantUtils // contains filtered or unexported fields }
func NewContextFeegrantUtils ¶ added in v1.3.0
func NewContextFeegrantUtils(t require.TestingT, testContext testenv.TestContext, feegrantKeeper *feegrantkeeper.Keeper) *ContextFeegrantUtils
type ContextGovUtils ¶ added in v1.3.0
type ContextGovUtils struct { GovUtils // contains filtered or unexported fields }
func NewContextGovUtils ¶ added in v1.3.0
func NewContextGovUtils(t require.TestingT, testContext testenv.TestContext, govKeeper *govkeeper.Keeper) *ContextGovUtils
type ContextStakingUtils ¶
type ContextStakingUtils struct { StakingUtils // contains filtered or unexported fields }
func NewContextStakingUtils ¶
func NewContextStakingUtils(t require.TestingT, testContext testenv.TestContext, helperStakingkeeper stakingkeeper.Keeper, bankUtils *BankUtils) *ContextStakingUtils
func (*ContextStakingUtils) CreateValidator ¶
func (su *ContextStakingUtils) CreateValidator(addr sdk.ValAddress, pk cryptotypes.PubKey, coin sdk.Coin, commisions stakingtypes.CommissionRates)
func (*ContextStakingUtils) GetStakingDenom ¶ added in v1.3.0
func (su *ContextStakingUtils) GetStakingDenom() string
func (*ContextStakingUtils) GetValidator ¶
func (su *ContextStakingUtils) GetValidator(addr sdk.ValAddress) (validator stakingtypes.Validator, found bool)
func (*ContextStakingUtils) GetValidators ¶ added in v1.3.0
func (su *ContextStakingUtils) GetValidators() []stakingtypes.Validator
func (*ContextStakingUtils) MessageDelegate ¶
func (su *ContextStakingUtils) MessageDelegate(expectedCurrentAmountOfDelegations int, expectedCurrentAmountOfUnbondingDelegations int, validatorAddress sdk.ValAddress, delegatorAddress sdk.AccAddress, bondAmount math.Int)
func (*ContextStakingUtils) MessageUndelegate ¶
func (su *ContextStakingUtils) MessageUndelegate(expectedCurrentAmountOfDelegations int, expectedCurrentAmountOfUnbondingDelegations int, validatorAddress sdk.ValAddress, delegatorAddress sdk.AccAddress, unbondAmount math.Int)
func (*ContextStakingUtils) SetupValidators ¶
func (su *ContextStakingUtils) SetupValidators(validators []sdk.ValAddress, delegatePerValidator math.Int)
func (*ContextStakingUtils) VerifyNumberOfUnbondingDelegations ¶
func (su *ContextStakingUtils) VerifyNumberOfUnbondingDelegations(expectedNumberOfUnbondingDelegations int, delegatorAddress sdk.AccAddress)
type DistributionUtils ¶ added in v1.3.0
type DistributionUtils struct { DistrKeeper *distrkeeper.Keeper // contains filtered or unexported fields }
func NewDistributionUtils ¶ added in v1.3.0
func NewDistributionUtils(t require.TestingT, distrKeeper *distrkeeper.Keeper) DistributionUtils
type FeegrantUtils ¶ added in v1.3.0
type FeegrantUtils struct { FeegrantKeeper *feegrantkeeper.Keeper // contains filtered or unexported fields }
func NewFeegrantUtils ¶ added in v1.3.0
func NewFeegrantUtils(t require.TestingT, feegrantKeeper *feegrantkeeper.Keeper) FeegrantUtils
type StakingUtils ¶
type StakingUtils struct {
// contains filtered or unexported fields
}
func NewStakingUtils ¶
func NewStakingUtils(t require.TestingT, helperStakingkeeper stakingkeeper.Keeper, bankUtils *BankUtils) StakingUtils
func (*StakingUtils) CreateValidator ¶
func (su *StakingUtils) CreateValidator(ctx sdk.Context, addr sdk.ValAddress, pk cryptotypes.PubKey, coin sdk.Coin, commisions stakingtypes.CommissionRates)
func (*StakingUtils) GetStakingDenom ¶ added in v1.3.0
func (su *StakingUtils) GetStakingDenom(ctx sdk.Context) string
func (*StakingUtils) GetValidator ¶
func (su *StakingUtils) GetValidator(ctx sdk.Context, addr sdk.ValAddress) (validator stakingtypes.Validator, found bool)
func (*StakingUtils) GetValidators ¶ added in v1.3.0
func (su *StakingUtils) GetValidators(ctx sdk.Context) []stakingtypes.Validator
func (*StakingUtils) MessageDelegate ¶
func (su *StakingUtils) MessageDelegate(ctx sdk.Context, expectedCurrentAmountOfDelegations int, expectedCurrentAmountOfUnbondingDelegations int, validatorAddress sdk.ValAddress, delegatorAddress sdk.AccAddress, bondAmount math.Int)
func (*StakingUtils) MessageUndelegate ¶
func (su *StakingUtils) MessageUndelegate(ctx sdk.Context, expectedCurrentAmountOfDelegations int, expectedCurrentAmountOfUnbondingDelegations int, validatorAddress sdk.ValAddress, delegatorAddress sdk.AccAddress, unbondAmount math.Int)
func (*StakingUtils) SetupValidators ¶
func (su *StakingUtils) SetupValidators(ctx sdk.Context, validators []sdk.ValAddress, delegatePerValidator math.Int)
func (*StakingUtils) VerifyNumberOfUnbondingDelegations ¶
func (su *StakingUtils) VerifyNumberOfUnbondingDelegations(ctx sdk.Context, expectedNumberOfUnbondingDelegations int, delegatorAddress sdk.AccAddress)
Click to show internal directories.
Click to hide internal directories.