Documentation ¶
Index ¶
- Variables
- func AccountKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore) authkeeper.AccountKeeper
- func AuthorityKeeper(t testing.TB) (*keeper.Keeper, sdk.Context)
- func BankKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) bankkeeper.Keeper
- func CapabilityKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore) *capabilitykeeper.Keeper
- func ConsensusKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore) consensuskeeper.Keeper
- func CrosschainKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func CrosschainKeeperAllMocks(t testing.TB) (*keeper.Keeper, sdk.Context)
- func CrosschainKeeperWithMocks(t testing.TB, mockOptions CrosschainMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func DistributionKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) distrkeeper.Keeper
- func EVMKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) *evmkeeper.Keeper
- func EmissionKeeperWithMockOptions(t testing.TB, mockOptions EmissionMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func EmissionsKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func FeeMarketKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) feemarketkeeper.Keeper
- func FungibleKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func FungibleKeeperAllMocks(t testing.TB) (*keeper.Keeper, sdk.Context)
- func FungibleKeeperWithMocks(t testing.TB, mockOptions FungibleMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func GetCrosschainAccountMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainAccountKeeper
- func GetCrosschainAuthorityMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainAuthorityKeeper
- func GetCrosschainBankMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainBankKeeper
- func GetCrosschainFungibleMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainFungibleKeeper
- func GetCrosschainLightclientMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainLightclientKeeper
- func GetCrosschainObserverMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainObserverKeeper
- func GetCrosschainStakingMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainStakingKeeper
- func GetEmissionsBankMock(t testing.TB, keeper *keeper.Keeper) *emissionsmocks.EmissionBankKeeper
- func GetEmissionsStakingMock(t testing.TB, keeper *keeper.Keeper) *emissionsmocks.EmissionStakingKeeper
- func GetFungibleAccountMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleAccountKeeper
- func GetFungibleAuthorityMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleAuthorityKeeper
- func GetFungibleBankMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleBankKeeper
- func GetFungibleObserverMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleObserverKeeper
- func GetLightclientAuthorityMock(t testing.TB, keeper *keeper.Keeper) *lightclientmocks.LightclientAuthorityKeeper
- func GetObserverAuthorityMock(t testing.TB, keeper *keeper.Keeper) *observermocks.ObserverAuthorityKeeper
- func GetObserverLightclientMock(t testing.TB, keeper *keeper.Keeper) *observermocks.ObserverLightclientKeeper
- func IBCCrosschainKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func IBCCrosschainKeeperAllMocks(t testing.TB) (*keeper.Keeper, sdk.Context)
- func IBCCrosschainKeeperWithMocks(t testing.TB, mockOptions IBCCroscchainMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func IBCKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) *ibckeeper.Keeper
- func LightclientKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func LightclientKeeperWithMocks(t testing.TB, mockOptions LightclientMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func MockCctxByNonce(t *testing.T, ctx sdk.Context, k keeper.Keeper, ...)
- func MockCheckAuthorization(m *mock.Mock, msg sdk.Msg, authorizationResult error)
- func MockFailedGetSupportedChainFromChainID(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain)
- func MockGetChainList(m *mock.Mock, chainList []chains.Chain)
- func MockGetChainListEmpty(m *mock.Mock)
- func MockGetRevertGasLimitForERC20(m *crosschainmocks.CrosschainFungibleKeeper, asset string, ...)
- func MockGetSupportedChainFromChainID(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain)
- func MockPayGasAndUpdateCCTX(m *crosschainmocks.CrosschainFungibleKeeper, ...)
- func MockRevertForHandleEVMDeposit(m *crosschainmocks.CrosschainFungibleKeeper, receiver ethcommon.Address, ...)
- func MockSaveOutbound(m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, ...)
- func MockSaveOutboundNewRevertCreated(m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, ...)
- func MockUpdateNonce(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain) (nonce uint64)
- func MockVoteOnOutboundFailedBallot(m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, ...)
- func MockVoteOnOutboundSuccessBallot(m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, ...)
- func ModuleAccountAddrs(maccPerms map[string][]string) map[string]bool
- func NewCodec() *codec.ProtoCodec
- func NewContext(stateStore sdk.MultiStore) sdk.Context
- func ObserverKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func ObserverKeeperWithMocks(t testing.TB, mockOptions ObserverMockOptions) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
- func ParamsKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore) paramskeeper.Keeper
- func SetAdminPolicies(ctx sdk.Context, ak *keeper.Keeper) string
- func SlashingKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) slashingkeeper.Keeper
- func StakingKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) stakingkeeper.Keeper
- func StoreKeys() (map[string]*storetypes.KVStoreKey, map[string]*storetypes.MemoryStoreKey, ...)
- func TransferKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ...) ibctransferkeeper.Keeper
- func UpgradeKeeper(cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore) upgradekeeper.Keeper
- type CrosschainMockOptions
- type EmissionMockOptions
- type FungibleMockEVMKeeper
- func (m *FungibleMockEVMKeeper) MockEVMFailCallOnce()
- func (m *FungibleMockEVMKeeper) MockEVMSuccessCallOnce()
- func (m *FungibleMockEVMKeeper) MockEVMSuccessCallOnceWithReturn(ret *evmtypes.MsgEthereumTxResponse)
- func (m *FungibleMockEVMKeeper) MockEVMSuccessCallTimes(times int)
- func (m *FungibleMockEVMKeeper) MockEVMSuccessCallTimesWithReturn(ret *evmtypes.MsgEthereumTxResponse, times int)
- func (m *FungibleMockEVMKeeper) SetupMockEVMKeeperForSystemContractDeployment()
- type FungibleMockOptions
- type IBCCroscchainMockOptions
- type LightclientMockOptions
- type ObserverMockOptions
- type ObserverMockSlashingKeeper
- type ObserverMockStakingKeeper
- type ProtocolVersionSetter
- type SDKKeepers
- type ZetaKeepers
Constants ¶
This section is empty.
Variables ¶
var ( CrosschainMocksAll = CrosschainMockOptions{ UseBankMock: true, UseAccountMock: true, UseStakingMock: true, UseObserverMock: true, UseFungibleMock: true, UseAuthorityMock: true, UseLightclientMock: true, UseIBCCrosschainMock: true, } CrosschainNoMocks = CrosschainMockOptions{} )
var ( FungibleMocksAll = FungibleMockOptions{ UseBankMock: true, UseAccountMock: true, UseObserverMock: true, UseEVMMock: true, UseAuthorityMock: true, } FungibleNoMocks = FungibleMockOptions{} )
var ( IBCCrosschainMocksAll = IBCCroscchainMockOptions{ UseCrosschainMock: true, UseIBCTransferMock: true, } IBCCrosschainNoMocks = IBCCroscchainMockOptions{} )
var ( LightclientMocksAll = LightclientMockOptions{ UseAuthorityMock: true, } LightclientNoMocks = LightclientMockOptions{} )
var ( ObserverMocksAll = ObserverMockOptions{ UseStakingMock: true, UseSlashingMock: true, UseAuthorityMock: true, UseLightclientMock: true, } ObserverNoMocks = ObserverMockOptions{} )
var (
AuthorityGovAddress = sample.Bech32AccAddress()
)
Functions ¶
func AccountKeeper ¶
func AccountKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) authkeeper.AccountKeeper
AccountKeeper instantiates an account keeper for testing purposes
func AuthorityKeeper ¶
AuthorityKeeper instantiates an authority keeper for testing purposes
func BankKeeper ¶
func BankKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, authKeeper authkeeper.AccountKeeper, ) bankkeeper.Keeper
BankKeeper instantiates a bank keeper for testing purposes
func CapabilityKeeper ¶
func CapabilityKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) *capabilitykeeper.Keeper
CapabilityKeeper instantiates a capability keeper for testing purposes
func ConsensusKeeper ¶
func ConsensusKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) consensuskeeper.Keeper
func CrosschainKeeper ¶
func CrosschainKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
CrosschainKeeper initializes a crosschain keeper for testing purposes
func CrosschainKeeperAllMocks ¶
CrosschainKeeperAllMocks initializes a crosschain keeper for testing purposes with all mocks
func CrosschainKeeperWithMocks ¶
func CrosschainKeeperWithMocks( t testing.TB, mockOptions CrosschainMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
CrosschainKeeperWithMocks initializes a crosschain keeper for testing purposes with option to mock specific keepers
func DistributionKeeper ¶
func DistributionKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, authKeeper authkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, stakingKeeper *stakingkeeper.Keeper, ) distrkeeper.Keeper
DistributionKeeper instantiates a distribution keeper for testing purposes
func EVMKeeper ¶
func EVMKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, authKeeper authkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, stakingKeeper stakingkeeper.Keeper, feemarketKeeper feemarketkeeper.Keeper, paramKeeper paramskeeper.Keeper, consensusKeeper consensuskeeper.Keeper, ) *evmkeeper.Keeper
EVMKeeper instantiates an evm keeper for testing purposes
func EmissionKeeperWithMockOptions ¶
func EmissionKeeperWithMockOptions( t testing.TB, mockOptions EmissionMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
func EmissionsKeeper ¶
func EmissionsKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
func FeeMarketKeeper ¶
func FeeMarketKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, paramKeeper paramskeeper.Keeper, consensusKeeper consensuskeeper.Keeper, ) feemarketkeeper.Keeper
FeeMarketKeeper instantiates a feemarket keeper for testing purposes
func FungibleKeeper ¶
func FungibleKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
FungibleKeeper initializes a fungible keeper for testing purposes
func FungibleKeeperAllMocks ¶
FungibleKeeperAllMocks initializes a fungible keeper for testing purposes with all keeper mocked
func FungibleKeeperWithMocks ¶
func FungibleKeeperWithMocks( t testing.TB, mockOptions FungibleMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
FungibleKeeperWithMocks initializes a fungible keeper for testing purposes with option to mock specific keepers
func GetCrosschainAccountMock ¶
func GetCrosschainAccountMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainAccountKeeper
func GetCrosschainAuthorityMock ¶
func GetCrosschainAuthorityMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainAuthorityKeeper
GetCrosschainAuthorityMock returns a new crosschain authority keeper mock
func GetCrosschainBankMock ¶
func GetCrosschainBankMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainBankKeeper
func GetCrosschainFungibleMock ¶
func GetCrosschainFungibleMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainFungibleKeeper
func GetCrosschainLightclientMock ¶
func GetCrosschainLightclientMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainLightclientKeeper
GetCrosschainLightclientMock returns a new crosschain lightclient keeper mock
func GetCrosschainObserverMock ¶
func GetCrosschainObserverMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainObserverKeeper
func GetCrosschainStakingMock ¶
func GetCrosschainStakingMock(t testing.TB, keeper *keeper.Keeper) *crosschainmocks.CrosschainStakingKeeper
func GetEmissionsBankMock ¶
func GetEmissionsBankMock(t testing.TB, keeper *keeper.Keeper) *emissionsmocks.EmissionBankKeeper
func GetEmissionsStakingMock ¶
func GetEmissionsStakingMock(t testing.TB, keeper *keeper.Keeper) *emissionsmocks.EmissionStakingKeeper
func GetFungibleAccountMock ¶
func GetFungibleAccountMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleAccountKeeper
func GetFungibleAuthorityMock ¶
func GetFungibleAuthorityMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleAuthorityKeeper
GetFungibleAuthorityMock returns a new fungible authority keeper mock
func GetFungibleBankMock ¶
func GetFungibleBankMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleBankKeeper
func GetFungibleObserverMock ¶
func GetFungibleObserverMock(t testing.TB, keeper *keeper.Keeper) *fungiblemocks.FungibleObserverKeeper
func GetLightclientAuthorityMock ¶
func GetLightclientAuthorityMock(t testing.TB, keeper *keeper.Keeper) *lightclientmocks.LightclientAuthorityKeeper
GetLightclientAuthorityMock returns a new lightclient authority keeper mock
func GetObserverAuthorityMock ¶
func GetObserverAuthorityMock(t testing.TB, keeper *keeper.Keeper) *observermocks.ObserverAuthorityKeeper
GetObserverAuthorityMock returns a new observer authority keeper mock
func GetObserverLightclientMock ¶
func GetObserverLightclientMock(t testing.TB, keeper *keeper.Keeper) *observermocks.ObserverLightclientKeeper
GetObserverLightclientMock returns a new observer lightclient keeper mock
func IBCCrosschainKeeper ¶
func IBCCrosschainKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
IBCCrosschainKeeper creates a new ibccrosschain keeper with no mocked keepers
func IBCCrosschainKeeperAllMocks ¶
IBCCrosschainKeeperAllMocks creates a new ibccrosschain keeper with all mocked keepers
func IBCCrosschainKeeperWithMocks ¶
func IBCCrosschainKeeperWithMocks( t testing.TB, mockOptions IBCCroscchainMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
func IBCKeeper ¶
func IBCKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, paramKeeper paramskeeper.Keeper, stakingKeeper stakingkeeper.Keeper, uppgradeKeeper upgradekeeper.Keeper, capabilityKeeper capabilitykeeper.Keeper, ) *ibckeeper.Keeper
IBCKeeper instantiates an ibc keeper for testing purposes
func LightclientKeeper ¶
func LightclientKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
LightclientKeeper instantiates an lightclient keeper for testing purposes
func LightclientKeeperWithMocks ¶
func LightclientKeeperWithMocks( t testing.TB, mockOptions LightclientMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
LightclientKeeperWithMocks instantiates a lightclient keeper for testing purposes with the option to mock specific keepers
func MockCctxByNonce ¶
func MockCctxByNonce( t *testing.T, ctx sdk.Context, k keeper.Keeper, observerKeeper *crosschainmocks.CrosschainObserverKeeper, cctxStatus types.CctxStatus, isErr bool, )
MockCctxByNonce is a utility function using observer mock to returns a cctx of the given status from crosschain keeper mocks the methods called by CctxByNonce to directly return the given cctx or error
func MockCheckAuthorization ¶
MockCheckAuthorization mocks the CheckAuthorization method of the authority keeper.
func MockFailedGetSupportedChainFromChainID ¶
func MockFailedGetSupportedChainFromChainID(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain)
func MockGetChainList ¶
MockGetChainList mocks the GetAdditionalChainList method of the authority keeper.
func MockGetChainListEmpty ¶
MockGetChainListEmpty mocks the GetAdditionalChainList method of the authority keeper.
func MockGetRevertGasLimitForERC20 ¶
func MockGetRevertGasLimitForERC20( m *crosschainmocks.CrosschainFungibleKeeper, asset string, senderChain chains.Chain, returnVal int64, )
func MockGetSupportedChainFromChainID ¶
func MockGetSupportedChainFromChainID(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain)
func MockPayGasAndUpdateCCTX ¶
func MockPayGasAndUpdateCCTX( m *crosschainmocks.CrosschainFungibleKeeper, m2 *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, k keeper.Keeper, senderChain chains.Chain, asset string, )
func MockRevertForHandleEVMDeposit ¶
func MockRevertForHandleEVMDeposit( m *crosschainmocks.CrosschainFungibleKeeper, receiver ethcommon.Address, amount *big.Int, senderChainID int64, errDeposit error, )
func MockSaveOutbound ¶
func MockSaveOutbound( m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, cctx *types.CrossChainTx, tss observertypes.TSS, expectedNumberOfOutboundParams int, )
func MockSaveOutboundNewRevertCreated ¶
func MockSaveOutboundNewRevertCreated( m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, cctx *types.CrossChainTx, tss observertypes.TSS, expectedNumberOfOutboundParams int, )
func MockUpdateNonce ¶
func MockUpdateNonce(m *crosschainmocks.CrosschainObserverKeeper, senderChain chains.Chain) (nonce uint64)
func MockVoteOnOutboundFailedBallot ¶
func MockVoteOnOutboundFailedBallot( m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, cctx *types.CrossChainTx, senderChain chains.Chain, observer string, )
func MockVoteOnOutboundSuccessBallot ¶
func MockVoteOnOutboundSuccessBallot( m *crosschainmocks.CrosschainObserverKeeper, ctx sdk.Context, cctx *types.CrossChainTx, senderChain chains.Chain, observer string, )
func ModuleAccountAddrs ¶
ModuleAccountAddrs returns all the app's module account addresses.
func NewCodec ¶
func NewCodec() *codec.ProtoCodec
func NewContext ¶
func NewContext(stateStore sdk.MultiStore) sdk.Context
NewContext creates a new sdk.Context for testing purposes with initialized header
func ObserverKeeper ¶
func ObserverKeeper(t testing.TB) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
ObserverKeeper instantiates an observer keeper for testing purposes
func ObserverKeeperWithMocks ¶
func ObserverKeeperWithMocks( t testing.TB, mockOptions ObserverMockOptions, ) (*keeper.Keeper, sdk.Context, SDKKeepers, ZetaKeepers)
ObserverKeeperWithMocks instantiates an observer keeper for testing purposes with the option to mock specific keepers
func ParamsKeeper ¶
func ParamsKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) paramskeeper.Keeper
ParamsKeeper instantiates a param keeper for testing purposes TODO: remove https://github.com/zeta-chain/node/issues/848
func SlashingKeeper ¶
func SlashingKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, stakingKeeper stakingkeeper.Keeper, ) slashingkeeper.Keeper
SlashingKeeper instantiates a slashing keeper for testing purposes
func StakingKeeper ¶
func StakingKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, authKeeper authkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, ) stakingkeeper.Keeper
StakingKeeper instantiates a staking keeper for testing purposes
func StoreKeys ¶
func StoreKeys() ( map[string]*storetypes.KVStoreKey, map[string]*storetypes.MemoryStoreKey, map[string]*storetypes.TransientStoreKey, map[string]storetypes.StoreKey, )
func TransferKeeper ¶
func TransferKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, paramKeeper paramskeeper.Keeper, ibcKeeper *ibckeeper.Keeper, authKeeper authkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, capabilityKeeper capabilitykeeper.Keeper, ibcRouter *porttypes.Router, ) ibctransferkeeper.Keeper
TransferKeeper instantiates an ibc transfer keeper for testing purposes
func UpgradeKeeper ¶
func UpgradeKeeper( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) upgradekeeper.Keeper
UpgradeKeeper instantiates an upgrade keeper for testing purposes
Types ¶
type CrosschainMockOptions ¶
type EmissionMockOptions ¶
type FungibleMockEVMKeeper ¶
type FungibleMockEVMKeeper struct {
*fungiblemocks.FungibleEVMKeeper
}
func GetFungibleEVMMock ¶
func GetFungibleEVMMock(t testing.TB, keeper *keeper.Keeper) *FungibleMockEVMKeeper
func (*FungibleMockEVMKeeper) MockEVMFailCallOnce ¶
func (m *FungibleMockEVMKeeper) MockEVMFailCallOnce()
func (*FungibleMockEVMKeeper) MockEVMSuccessCallOnce ¶
func (m *FungibleMockEVMKeeper) MockEVMSuccessCallOnce()
func (*FungibleMockEVMKeeper) MockEVMSuccessCallOnceWithReturn ¶
func (m *FungibleMockEVMKeeper) MockEVMSuccessCallOnceWithReturn(ret *evmtypes.MsgEthereumTxResponse)
func (*FungibleMockEVMKeeper) MockEVMSuccessCallTimes ¶
func (m *FungibleMockEVMKeeper) MockEVMSuccessCallTimes(times int)
func (*FungibleMockEVMKeeper) MockEVMSuccessCallTimesWithReturn ¶
func (m *FungibleMockEVMKeeper) MockEVMSuccessCallTimesWithReturn(ret *evmtypes.MsgEthereumTxResponse, times int)
func (*FungibleMockEVMKeeper) SetupMockEVMKeeperForSystemContractDeployment ¶
func (m *FungibleMockEVMKeeper) SetupMockEVMKeeperForSystemContractDeployment()
type FungibleMockOptions ¶
type LightclientMockOptions ¶
type LightclientMockOptions struct {
UseAuthorityMock bool
}
LightclientMockOptions represents options for instantiating a lightclient keeper with mocks
type ObserverMockOptions ¶
type ObserverMockOptions struct { UseStakingMock bool UseSlashingMock bool UseAuthorityMock bool UseLightclientMock bool }
ObserverMockOptions represents options for instantiating an observer keeper with mocks
type ObserverMockSlashingKeeper ¶
type ObserverMockSlashingKeeper struct {
*observermocks.ObserverSlashingKeeper
}
ObserverMockSlashingKeeper is a wrapper of the observer slashing keeper mock that add methods to mock the IsTombstoned method
func GetObserverSlashingMock ¶
func GetObserverSlashingMock(t testing.TB, keeper *keeper.Keeper) *ObserverMockSlashingKeeper
GetObserverSlashingMock returns a new observer slashing keeper mock
func (*ObserverMockSlashingKeeper) MockIsTombstoned ¶
func (m *ObserverMockSlashingKeeper) MockIsTombstoned(isTombstoned bool)
type ObserverMockStakingKeeper ¶
type ObserverMockStakingKeeper struct {
*observermocks.ObserverStakingKeeper
}
ObserverMockStakingKeeper is a wrapper of the observer staking keeper mock that add methods to mock the GetValidator method
func GetObserverStakingMock ¶
func GetObserverStakingMock(t testing.TB, keeper *keeper.Keeper) *ObserverMockStakingKeeper
GetObserverStakingMock returns a new observer staking keeper mock
func (*ObserverMockStakingKeeper) MockGetValidator ¶
func (m *ObserverMockStakingKeeper) MockGetValidator(validator stakingtypes.Validator)
type ProtocolVersionSetter ¶
type ProtocolVersionSetter struct{}
ProtocolVersionSetter mock
func (ProtocolVersionSetter) SetProtocolVersion ¶
func (vs ProtocolVersionSetter) SetProtocolVersion(uint64)
type SDKKeepers ¶
type SDKKeepers struct { ParamsKeeper paramskeeper.Keeper AuthKeeper authkeeper.AccountKeeper BankKeeper bankkeeper.Keeper StakingKeeper stakingkeeper.Keeper SlashingKeeper slashingkeeper.Keeper FeeMarketKeeper feemarketkeeper.Keeper EvmKeeper *evmkeeper.Keeper CapabilityKeeper *capabilitykeeper.Keeper IBCKeeper *ibckeeper.Keeper TransferKeeper ibctransferkeeper.Keeper ScopedIBCKeeper capabilitykeeper.ScopedKeeper ScopedTransferKeeper capabilitykeeper.ScopedKeeper IBCRouter *porttypes.Router }
SDKKeepers is a struct containing regular SDK module keepers for test purposes
func NewSDKKeepers ¶
func NewSDKKeepers( cdc codec.Codec, db *tmdb.MemDB, ss store.CommitMultiStore, ) SDKKeepers
NewSDKKeepers instantiates regular Cosmos SDK keeper such as staking with local storage for testing purposes
func NewSDKKeepersWithKeys ¶
func NewSDKKeepersWithKeys( cdc codec.Codec, keys map[string]*storetypes.KVStoreKey, memKeys map[string]*storetypes.MemoryStoreKey, tKeys map[string]*storetypes.TransientStoreKey, allKeys map[string]storetypes.StoreKey, ) SDKKeepers
NewSDKKeepers instantiates regular Cosmos SDK keeper such as staking with local storage for testing purposes
func (SDKKeepers) InitBlockProposer ¶
InitBlockProposer initialize the block proposer for test purposes with an associated validator
func (SDKKeepers) InitGenesis ¶
func (sdkk SDKKeepers) InitGenesis(ctx sdk.Context)
InitGenesis initializes the test modules genesis state
type ZetaKeepers ¶
type ZetaKeepers struct { AuthorityKeeper *authoritykeeper.Keeper CrosschainKeeper *crosschainkeeper.Keeper EmissionsKeeper *emissionskeeper.Keeper FungibleKeeper *fungiblekeeper.Keeper ObserverKeeper *observerkeeper.Keeper LightclientKeeper *lightclientkeeper.Keeper IBCCrosschainKeeper *ibccrosschainkeeper.Keeper }
ZetaKeepers is a struct containing Zeta module keepers for test purposes
func (ZetaKeepers) InitGenesis ¶
func (zk ZetaKeepers) InitGenesis(ctx sdk.Context)
InitGenesis initializes the test modules genesis state for defined Zeta modules