Documentation ¶
Index ¶
- Variables
- type Suite
- func (suite *Suite) AccountBalanceEqual(addr sdk.AccAddress, coins sdk.Coins)
- func (suite *Suite) AddCoinsToModule(amount sdk.Coins)
- func (suite *Suite) CreateAccount(initialBalance sdk.Coins, index int) authtypes.AccountI
- func (suite *Suite) CreateDelegation(valAddr sdk.ValAddress, delegator sdk.AccAddress, amount sdkmath.Int) sdk.Dec
- func (suite *Suite) CreateNewUnbondedValidator(addr sdk.ValAddress, selfDelegation sdkmath.Int) stakingtypes.Validator
- func (suite *Suite) CreateVault(vaultDenom string, vaultStrategies types.StrategyTypes, isPrivateVault bool, ...)
- func (suite *Suite) EventsContains(events sdk.Events, expectedEvent sdk.Event)
- func (suite *Suite) GetEvents() sdk.Events
- func (suite *Suite) JinxDepositAmountEqual(expected sdk.Coins)
- func (suite *Suite) ModuleAccountBalanceEqual(coins sdk.Coins)
- func (suite *Suite) NewAccountFromAddr(addr sdk.AccAddress, balance sdk.Coins) authtypes.AccountI
- func (suite *Suite) NewBondCoin(amount sdkmath.Int) sdk.Coin
- func (suite *Suite) RemoveCoinsFromModule(amount sdk.Coins)
- func (suite *Suite) SavingsDepositAmountEqual(expected sdk.Coins)
- func (suite *Suite) SetupTest()
- func (suite *Suite) VaultAccountSharesEqual(accs []sdk.AccAddress, supplies []sdk.Coins)
- func (suite *Suite) VaultTotalSharesEqual(expected types.VaultShares)
- func (suite *Suite) VaultTotalValuesEqual(expected sdk.Coins)
Constants ¶
This section is empty.
Variables ¶
var TestBfuryDenoms = []string{
"bfury-furyvaloper15gqc744d05xacn4n6w2furuads9fu4pqn6zxlu",
"bfury-furyvaloper15qdefkmwswysgg4qxgqpqr35k3m49pkx8yhpte",
"bfury-furyvaloper1ypjp0m04pyp73hwgtc0dgkx0e9rrydeckewa42",
}
Functions ¶
This section is empty.
Types ¶
type Suite ¶
type Suite struct { suite.Suite Keeper keeper.Keeper App app.TestApp Ctx sdk.Context BankKeeper bankkeeper.Keeper AccountKeeper authkeeper.AccountKeeper // Strategy Keepers JinxKeeper jinxkeeper.Keeper SavingsKeeper savingskeeper.Keeper }
Suite implements a test suite for the earn module integration tests
func (*Suite) AccountBalanceEqual ¶
func (suite *Suite) AccountBalanceEqual(addr sdk.AccAddress, coins sdk.Coins)
AccountBalanceEqual asserts that the coins match the account balance
func (*Suite) AddCoinsToModule ¶
AddCoinsToModule adds coins to the earn module account
func (*Suite) CreateAccount ¶
CreateAccount creates a new account from the provided balance, using index to create different new addresses.
func (*Suite) CreateDelegation ¶
func (suite *Suite) CreateDelegation(valAddr sdk.ValAddress, delegator sdk.AccAddress, amount sdkmath.Int) sdk.Dec
CreateDelegation delegates tokens to a validator.
func (*Suite) CreateNewUnbondedValidator ¶
func (suite *Suite) CreateNewUnbondedValidator(addr sdk.ValAddress, selfDelegation sdkmath.Int) stakingtypes.Validator
CreateNewUnbondedValidator creates a new validator in the staking module. New validators are unbonded until the end blocker is run.
func (*Suite) CreateVault ¶
func (suite *Suite) CreateVault( vaultDenom string, vaultStrategies types.StrategyTypes, isPrivateVault bool, allowedDepositors []sdk.AccAddress, )
CreateVault adds a new vault to the keeper parameters
func (*Suite) EventsContains ¶
EventsContains asserts that the expected event is in the provided events
func (*Suite) JinxDepositAmountEqual ¶
JinxDepositAmountEqual asserts that the jinx deposit amount matches the provided values.
func (*Suite) ModuleAccountBalanceEqual ¶
ModuleAccountBalanceEqual asserts that the earn module account balance matches the provided coins
func (*Suite) NewAccountFromAddr ¶
NewAccountFromAddr creates a new account from the provided address with the provided balance
func (*Suite) NewBondCoin ¶
NewBondCoin creates a Coin with the current staking denom.
func (*Suite) RemoveCoinsFromModule ¶
RemoveCoinsFromModule removes coins to the earn module account
func (*Suite) SavingsDepositAmountEqual ¶
SavingsDepositAmountEqual asserts that the savings deposit amount matches the provided values.
func (*Suite) SetupTest ¶
func (suite *Suite) SetupTest()
SetupTest instantiates a new app, keepers, and sets suite state
func (*Suite) VaultAccountSharesEqual ¶
func (suite *Suite) VaultAccountSharesEqual(accs []sdk.AccAddress, supplies []sdk.Coins)
VaultAccountSharesEqual asserts that the vault account shares match the provided values.
func (*Suite) VaultTotalSharesEqual ¶
func (suite *Suite) VaultTotalSharesEqual(expected types.VaultShares)
VaultTotalSharesEqual asserts that the vault total shares match the provided values.
func (*Suite) VaultTotalValuesEqual ¶
VaultTotalValuesEqual asserts that the vault total values match the provided values.