keeper

package
v0.0.0-...-538a0af Latest Latest
Warning

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

Go to latest
Published: May 19, 2026 License: Apache-2.0 Imports: 36 Imported by: 0

Documentation

Overview

Package keeper is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExpectCreateClientMock

func ExpectCreateClientMock(ctx sdk.Context, mocks MockedKeepers, clientType, clientID string,
	clientState, consState []byte,
) *gomock.Call

func GetNewCrossChainValidator

func GetNewCrossChainValidator(t *testing.T) consumertypes.CrossChainValidator

Obtains a CrossChainValidator with a newly generated key, and randomized field values

func NewInMemConsumerKeeper

func NewInMemConsumerKeeper(params InMemKeeperParams, mocks MockedKeepers) consumerkeeper.Keeper

NewInMemConsumerKeeper instantiates an in-mem consumer keeper from params and mocked keepers

func NewInMemProviderKeeper

func NewInMemProviderKeeper(params InMemKeeperParams, mocks MockedKeepers) providerkeeper.Keeper

NewInMemProviderKeeper instantiates an in-mem provider keeper from params and mocked keepers

func SetupMocksForLastBondedValidatorsExpectation

func SetupMocksForLastBondedValidatorsExpectation(mockStakingKeeper *MockStakingKeeper, maxValidators uint32, vals []stakingtypes.Validator, times int)

Types

type InMemKeeperParams

type InMemKeeperParams struct {
	Cdc      *codec.ProtoCodec
	StoreKey *storetypes.KVStoreKey
	Ctx      sdk.Context
}

InMemKeeperParams parameters needed to instantiate an in-memory keeper

func NewInMemKeeperParams

func NewInMemKeeperParams(tb testing.TB) InMemKeeperParams

NewInMemKeeperParams instantiates in-memory keeper params with default values

type MockAccountKeeper

type MockAccountKeeper struct {
	// contains filtered or unexported fields
}

MockAccountKeeper is a mock of AccountKeeper interface.

func NewMockAccountKeeper

func NewMockAccountKeeper(ctrl *gomock.Controller) *MockAccountKeeper

NewMockAccountKeeper creates a new mock instance.

func (*MockAccountKeeper) AddressCodec

func (m *MockAccountKeeper) AddressCodec() address.Codec

AddressCodec mocks base method.

func (*MockAccountKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockAccountKeeper) GetModuleAccount

func (m *MockAccountKeeper) GetModuleAccount(ctx context.Context, name string) types.ModuleAccountI

GetModuleAccount mocks base method.

type MockAccountKeeperMockRecorder

type MockAccountKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockAccountKeeperMockRecorder is the mock recorder for MockAccountKeeper.

func (*MockAccountKeeperMockRecorder) AddressCodec

func (mr *MockAccountKeeperMockRecorder) AddressCodec() *gomock.Call

AddressCodec indicates an expected call of AddressCodec.

func (*MockAccountKeeperMockRecorder) GetModuleAccount

func (mr *MockAccountKeeperMockRecorder) GetModuleAccount(ctx, name any) *gomock.Call

GetModuleAccount indicates an expected call of GetModuleAccount.

type MockBankKeeper

type MockBankKeeper struct {
	// contains filtered or unexported fields
}

MockBankKeeper is a mock of BankKeeper interface.

func NewMockBankKeeper

func NewMockBankKeeper(ctrl *gomock.Controller) *MockBankKeeper

NewMockBankKeeper creates a new mock instance.

func (*MockBankKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockBankKeeper) GetBalance

func (m *MockBankKeeper) GetBalance(ctx context.Context, addr types.AccAddress, denom string) types.Coin

GetBalance mocks base method.

func (*MockBankKeeper) SendCoinsFromAccountToModule

func (m *MockBankKeeper) SendCoinsFromAccountToModule(ctx context.Context, senderAddr types.AccAddress, recipientModule string, amt types.Coins) error

SendCoinsFromAccountToModule mocks base method.

func (*MockBankKeeper) SendCoinsFromModuleToAccount

func (m *MockBankKeeper) SendCoinsFromModuleToAccount(ctx context.Context, senderModule string, recipientAddr types.AccAddress, amt types.Coins) error

SendCoinsFromModuleToAccount mocks base method.

func (*MockBankKeeper) SendCoinsFromModuleToModule

func (m *MockBankKeeper) SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt types.Coins) error

SendCoinsFromModuleToModule mocks base method.

type MockBankKeeperMockRecorder

type MockBankKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockBankKeeperMockRecorder is the mock recorder for MockBankKeeper.

func (*MockBankKeeperMockRecorder) GetBalance

func (mr *MockBankKeeperMockRecorder) GetBalance(ctx, addr, denom any) *gomock.Call

GetBalance indicates an expected call of GetBalance.

func (*MockBankKeeperMockRecorder) SendCoinsFromAccountToModule

func (mr *MockBankKeeperMockRecorder) SendCoinsFromAccountToModule(ctx, senderAddr, recipientModule, amt any) *gomock.Call

SendCoinsFromAccountToModule indicates an expected call of SendCoinsFromAccountToModule.

func (*MockBankKeeperMockRecorder) SendCoinsFromModuleToAccount

func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToAccount(ctx, senderModule, recipientAddr, amt any) *gomock.Call

SendCoinsFromModuleToAccount indicates an expected call of SendCoinsFromModuleToAccount.

func (*MockBankKeeperMockRecorder) SendCoinsFromModuleToModule

func (mr *MockBankKeeperMockRecorder) SendCoinsFromModuleToModule(ctx, senderModule, recipientModule, amt any) *gomock.Call

SendCoinsFromModuleToModule indicates an expected call of SendCoinsFromModuleToModule.

type MockChannelV2Keeper

type MockChannelV2Keeper struct {
	// contains filtered or unexported fields
}

MockChannelV2Keeper is a mock of ChannelV2Keeper interface.

func NewMockChannelV2Keeper

func NewMockChannelV2Keeper(ctrl *gomock.Controller) *MockChannelV2Keeper

NewMockChannelV2Keeper creates a new mock instance.

func (*MockChannelV2Keeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockChannelV2Keeper) SendPacket

SendPacket mocks base method.

type MockChannelV2KeeperMockRecorder

type MockChannelV2KeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockChannelV2KeeperMockRecorder is the mock recorder for MockChannelV2Keeper.

func (*MockChannelV2KeeperMockRecorder) SendPacket

func (mr *MockChannelV2KeeperMockRecorder) SendPacket(ctx, msg any) *gomock.Call

SendPacket indicates an expected call of SendPacket.

type MockClientKeeper

type MockClientKeeper struct {
	// contains filtered or unexported fields
}

MockClientKeeper is a mock of ClientKeeper interface.

func NewMockClientKeeper

func NewMockClientKeeper(ctrl *gomock.Controller) *MockClientKeeper

NewMockClientKeeper creates a new mock instance.

func (*MockClientKeeper) CreateClient

func (m *MockClientKeeper) CreateClient(ctx types.Context, clientType string, clientState, consensusState []byte) (string, error)

CreateClient mocks base method.

func (*MockClientKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockClientKeeper) GetClientConsensusState

func (m *MockClientKeeper) GetClientConsensusState(ctx types.Context, clientID string, height exported.Height) (exported.ConsensusState, bool)

GetClientConsensusState mocks base method.

func (*MockClientKeeper) GetClientState

func (m *MockClientKeeper) GetClientState(ctx types.Context, clientID string) (exported.ClientState, bool)

GetClientState mocks base method.

func (*MockClientKeeper) GetClientStatus

func (m *MockClientKeeper) GetClientStatus(ctx types.Context, clientID string) exported.Status

GetClientStatus mocks base method.

func (*MockClientKeeper) GetStoreProvider

func (m *MockClientKeeper) GetStoreProvider() types2.StoreProvider

GetStoreProvider mocks base method.

func (*MockClientKeeper) IterateClientStates

func (m *MockClientKeeper) IterateClientStates(ctx types.Context, storePrefix []byte, cb func(string, exported.ClientState) bool)

IterateClientStates mocks base method.

type MockClientKeeperMockRecorder

type MockClientKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockClientKeeperMockRecorder is the mock recorder for MockClientKeeper.

func (*MockClientKeeperMockRecorder) CreateClient

func (mr *MockClientKeeperMockRecorder) CreateClient(ctx, clientType, clientState, consensusState any) *gomock.Call

CreateClient indicates an expected call of CreateClient.

func (*MockClientKeeperMockRecorder) GetClientConsensusState

func (mr *MockClientKeeperMockRecorder) GetClientConsensusState(ctx, clientID, height any) *gomock.Call

GetClientConsensusState indicates an expected call of GetClientConsensusState.

func (*MockClientKeeperMockRecorder) GetClientState

func (mr *MockClientKeeperMockRecorder) GetClientState(ctx, clientID any) *gomock.Call

GetClientState indicates an expected call of GetClientState.

func (*MockClientKeeperMockRecorder) GetClientStatus

func (mr *MockClientKeeperMockRecorder) GetClientStatus(ctx, clientID any) *gomock.Call

GetClientStatus indicates an expected call of GetClientStatus.

func (*MockClientKeeperMockRecorder) GetStoreProvider

func (mr *MockClientKeeperMockRecorder) GetStoreProvider() *gomock.Call

GetStoreProvider indicates an expected call of GetStoreProvider.

func (*MockClientKeeperMockRecorder) IterateClientStates

func (mr *MockClientKeeperMockRecorder) IterateClientStates(ctx, storePrefix, cb any) *gomock.Call

IterateClientStates indicates an expected call of IterateClientStates.

type MockClientV2Keeper

type MockClientV2Keeper struct {
	// contains filtered or unexported fields
}

MockClientV2Keeper is a mock of ClientV2Keeper interface.

func NewMockClientV2Keeper

func NewMockClientV2Keeper(ctrl *gomock.Controller) *MockClientV2Keeper

NewMockClientV2Keeper creates a new mock instance.

func (*MockClientV2Keeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockClientV2Keeper) GetClientCounterparty

func (m *MockClientV2Keeper) GetClientCounterparty(ctx types.Context, clientID string) (types3.CounterpartyInfo, bool)

GetClientCounterparty mocks base method.

func (*MockClientV2Keeper) SetClientCounterparty

func (m *MockClientV2Keeper) SetClientCounterparty(ctx types.Context, clientID string, counterparty types3.CounterpartyInfo)

SetClientCounterparty mocks base method.

type MockClientV2KeeperMockRecorder

type MockClientV2KeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockClientV2KeeperMockRecorder is the mock recorder for MockClientV2Keeper.

func (*MockClientV2KeeperMockRecorder) GetClientCounterparty

func (mr *MockClientV2KeeperMockRecorder) GetClientCounterparty(ctx, clientID any) *gomock.Call

GetClientCounterparty indicates an expected call of GetClientCounterparty.

func (*MockClientV2KeeperMockRecorder) SetClientCounterparty

func (mr *MockClientV2KeeperMockRecorder) SetClientCounterparty(ctx, clientID, counterparty any) *gomock.Call

SetClientCounterparty indicates an expected call of SetClientCounterparty.

type MockConsumerHooks

type MockConsumerHooks struct {
	// contains filtered or unexported fields
}

MockConsumerHooks is a mock of ConsumerHooks interface.

func NewMockConsumerHooks

func NewMockConsumerHooks(ctrl *gomock.Controller) *MockConsumerHooks

NewMockConsumerHooks creates a new mock instance.

func (*MockConsumerHooks) AfterValidatorBonded

func (m *MockConsumerHooks) AfterValidatorBonded(ctx context.Context, consAddr types.ConsAddress, valAddresses types.ValAddress) error

AfterValidatorBonded mocks base method.

func (*MockConsumerHooks) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockConsumerHooksMockRecorder

type MockConsumerHooksMockRecorder struct {
	// contains filtered or unexported fields
}

MockConsumerHooksMockRecorder is the mock recorder for MockConsumerHooks.

func (*MockConsumerHooksMockRecorder) AfterValidatorBonded

func (mr *MockConsumerHooksMockRecorder) AfterValidatorBonded(ctx, consAddr, valAddresses any) *gomock.Call

AfterValidatorBonded indicates an expected call of AfterValidatorBonded.

type MockIBCTransferKeeper

type MockIBCTransferKeeper struct {
	// contains filtered or unexported fields
}

MockIBCTransferKeeper is a mock of IBCTransferKeeper interface.

func NewMockIBCTransferKeeper

func NewMockIBCTransferKeeper(ctrl *gomock.Controller) *MockIBCTransferKeeper

NewMockIBCTransferKeeper creates a new mock instance.

func (*MockIBCTransferKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockIBCTransferKeeper) Transfer

Transfer mocks base method.

type MockIBCTransferKeeperMockRecorder

type MockIBCTransferKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockIBCTransferKeeperMockRecorder is the mock recorder for MockIBCTransferKeeper.

func (*MockIBCTransferKeeperMockRecorder) Transfer

func (mr *MockIBCTransferKeeperMockRecorder) Transfer(arg0, arg1 any) *gomock.Call

Transfer indicates an expected call of Transfer.

type MockSlashingKeeper

type MockSlashingKeeper struct {
	// contains filtered or unexported fields
}

MockSlashingKeeper is a mock of SlashingKeeper interface.

func NewMockSlashingKeeper

func NewMockSlashingKeeper(ctrl *gomock.Controller) *MockSlashingKeeper

NewMockSlashingKeeper creates a new mock instance.

func (*MockSlashingKeeper) DowntimeJailDuration

func (m *MockSlashingKeeper) DowntimeJailDuration(arg0 context.Context) (time.Duration, error)

DowntimeJailDuration mocks base method.

func (*MockSlashingKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockSlashingKeeper) IsTombstoned

func (m *MockSlashingKeeper) IsTombstoned(arg0 context.Context, arg1 types.ConsAddress) bool

IsTombstoned mocks base method.

func (*MockSlashingKeeper) JailUntil

func (m *MockSlashingKeeper) JailUntil(arg0 context.Context, arg1 types.ConsAddress, arg2 time.Time) error

JailUntil mocks base method.

func (*MockSlashingKeeper) SlashFractionDoubleSign

func (m *MockSlashingKeeper) SlashFractionDoubleSign(arg0 context.Context) (math.LegacyDec, error)

SlashFractionDoubleSign mocks base method.

func (*MockSlashingKeeper) Tombstone

func (m *MockSlashingKeeper) Tombstone(arg0 context.Context, arg1 types.ConsAddress) error

Tombstone mocks base method.

type MockSlashingKeeperMockRecorder

type MockSlashingKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockSlashingKeeperMockRecorder is the mock recorder for MockSlashingKeeper.

func (*MockSlashingKeeperMockRecorder) DowntimeJailDuration

func (mr *MockSlashingKeeperMockRecorder) DowntimeJailDuration(arg0 any) *gomock.Call

DowntimeJailDuration indicates an expected call of DowntimeJailDuration.

func (*MockSlashingKeeperMockRecorder) IsTombstoned

func (mr *MockSlashingKeeperMockRecorder) IsTombstoned(arg0, arg1 any) *gomock.Call

IsTombstoned indicates an expected call of IsTombstoned.

func (*MockSlashingKeeperMockRecorder) JailUntil

func (mr *MockSlashingKeeperMockRecorder) JailUntil(arg0, arg1, arg2 any) *gomock.Call

JailUntil indicates an expected call of JailUntil.

func (*MockSlashingKeeperMockRecorder) SlashFractionDoubleSign

func (mr *MockSlashingKeeperMockRecorder) SlashFractionDoubleSign(arg0 any) *gomock.Call

SlashFractionDoubleSign indicates an expected call of SlashFractionDoubleSign.

func (*MockSlashingKeeperMockRecorder) Tombstone

func (mr *MockSlashingKeeperMockRecorder) Tombstone(arg0, arg1 any) *gomock.Call

Tombstone indicates an expected call of Tombstone.

type MockStakingKeeper

type MockStakingKeeper struct {
	// contains filtered or unexported fields
}

MockStakingKeeper is a mock of StakingKeeper interface.

func NewMockStakingKeeper

func NewMockStakingKeeper(ctrl *gomock.Controller) *MockStakingKeeper

NewMockStakingKeeper creates a new mock instance.

func (*MockStakingKeeper) BondDenom

func (m *MockStakingKeeper) BondDenom(ctx context.Context) (string, error)

BondDenom mocks base method.

func (*MockStakingKeeper) BondedRatio

func (m *MockStakingKeeper) BondedRatio(ctx context.Context) (math.LegacyDec, error)

BondedRatio mocks base method.

func (*MockStakingKeeper) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockStakingKeeper) GetBondedValidatorsByPower

func (m *MockStakingKeeper) GetBondedValidatorsByPower(ctx context.Context) ([]types0.Validator, error)

GetBondedValidatorsByPower mocks base method.

func (*MockStakingKeeper) GetHistoricalInfo

func (m *MockStakingKeeper) GetHistoricalInfo(ctx context.Context, height int64) (types0.HistoricalInfo, error)

GetHistoricalInfo mocks base method.

func (*MockStakingKeeper) GetLastValidatorPower

func (m *MockStakingKeeper) GetLastValidatorPower(ctx context.Context, operator types.ValAddress) (int64, error)

GetLastValidatorPower mocks base method.

func (*MockStakingKeeper) GetRedelegationsFromSrcValidator

func (m *MockStakingKeeper) GetRedelegationsFromSrcValidator(ctx context.Context, valAddr types.ValAddress) ([]types0.Redelegation, error)

GetRedelegationsFromSrcValidator mocks base method.

func (*MockStakingKeeper) GetUnbondingDelegationsFromValidator

func (m *MockStakingKeeper) GetUnbondingDelegationsFromValidator(ctx context.Context, valAddr types.ValAddress) ([]types0.UnbondingDelegation, error)

GetUnbondingDelegationsFromValidator mocks base method.

func (*MockStakingKeeper) GetValidator

func (m *MockStakingKeeper) GetValidator(ctx context.Context, addr types.ValAddress) (types0.Validator, error)

GetValidator mocks base method.

func (*MockStakingKeeper) GetValidatorByConsAddr

func (m *MockStakingKeeper) GetValidatorByConsAddr(ctx context.Context, consAddr types.ConsAddress) (types0.Validator, error)

GetValidatorByConsAddr mocks base method.

func (*MockStakingKeeper) IterateBondedValidatorsByPower

func (m *MockStakingKeeper) IterateBondedValidatorsByPower(arg0 context.Context, arg1 func(int64, types0.ValidatorI) bool) error

IterateBondedValidatorsByPower mocks base method.

func (*MockStakingKeeper) IterateDelegations

func (m *MockStakingKeeper) IterateDelegations(ctx context.Context, delegator types.AccAddress, fn func(int64, types0.DelegationI) bool) error

IterateDelegations mocks base method.

func (*MockStakingKeeper) Jail

Jail mocks base method.

func (*MockStakingKeeper) MaxValidators

func (m *MockStakingKeeper) MaxValidators(ctx context.Context) (uint32, error)

MaxValidators mocks base method.

func (*MockStakingKeeper) PowerReduction

func (m *MockStakingKeeper) PowerReduction(ctx context.Context) math.Int

PowerReduction mocks base method.

func (*MockStakingKeeper) SlashRedelegation

func (m *MockStakingKeeper) SlashRedelegation(ctx context.Context, srcValidator types0.Validator, redelegation types0.Redelegation, infractionHeight int64, slashFactor math.LegacyDec) (math.Int, error)

SlashRedelegation mocks base method.

func (*MockStakingKeeper) SlashUnbondingDelegation

func (m *MockStakingKeeper) SlashUnbondingDelegation(ctx context.Context, unbondingDelegation types0.UnbondingDelegation, infractionHeight int64, slashFactor math.LegacyDec) (math.Int, error)

SlashUnbondingDelegation mocks base method.

func (*MockStakingKeeper) SlashWithInfractionReason

func (m *MockStakingKeeper) SlashWithInfractionReason(ctx context.Context, consAddr types.ConsAddress, infractionHeight, power int64, slashFactor math.LegacyDec, infraction types0.Infraction) (math.Int, error)

SlashWithInfractionReason mocks base method.

func (*MockStakingKeeper) StakingTokenSupply

func (m *MockStakingKeeper) StakingTokenSupply(ctx context.Context) (math.Int, error)

StakingTokenSupply mocks base method.

func (*MockStakingKeeper) TotalBondedTokens

func (m *MockStakingKeeper) TotalBondedTokens(ctx context.Context) (math.Int, error)

TotalBondedTokens mocks base method.

func (*MockStakingKeeper) UnbondingCanComplete

func (m *MockStakingKeeper) UnbondingCanComplete(ctx context.Context, id uint64) error

UnbondingCanComplete mocks base method.

func (*MockStakingKeeper) UnbondingTime

func (m *MockStakingKeeper) UnbondingTime(ctx context.Context) (time.Duration, error)

UnbondingTime mocks base method.

func (*MockStakingKeeper) ValidatorAddressCodec

func (m *MockStakingKeeper) ValidatorAddressCodec() address.Codec

ValidatorAddressCodec mocks base method.

type MockStakingKeeperMockRecorder

type MockStakingKeeperMockRecorder struct {
	// contains filtered or unexported fields
}

MockStakingKeeperMockRecorder is the mock recorder for MockStakingKeeper.

func (*MockStakingKeeperMockRecorder) BondDenom

func (mr *MockStakingKeeperMockRecorder) BondDenom(ctx any) *gomock.Call

BondDenom indicates an expected call of BondDenom.

func (*MockStakingKeeperMockRecorder) BondedRatio

func (mr *MockStakingKeeperMockRecorder) BondedRatio(ctx any) *gomock.Call

BondedRatio indicates an expected call of BondedRatio.

func (*MockStakingKeeperMockRecorder) GetBondedValidatorsByPower

func (mr *MockStakingKeeperMockRecorder) GetBondedValidatorsByPower(ctx any) *gomock.Call

GetBondedValidatorsByPower indicates an expected call of GetBondedValidatorsByPower.

func (*MockStakingKeeperMockRecorder) GetHistoricalInfo

func (mr *MockStakingKeeperMockRecorder) GetHistoricalInfo(ctx, height any) *gomock.Call

GetHistoricalInfo indicates an expected call of GetHistoricalInfo.

func (*MockStakingKeeperMockRecorder) GetLastValidatorPower

func (mr *MockStakingKeeperMockRecorder) GetLastValidatorPower(ctx, operator any) *gomock.Call

GetLastValidatorPower indicates an expected call of GetLastValidatorPower.

func (*MockStakingKeeperMockRecorder) GetRedelegationsFromSrcValidator

func (mr *MockStakingKeeperMockRecorder) GetRedelegationsFromSrcValidator(ctx, valAddr any) *gomock.Call

GetRedelegationsFromSrcValidator indicates an expected call of GetRedelegationsFromSrcValidator.

func (*MockStakingKeeperMockRecorder) GetUnbondingDelegationsFromValidator

func (mr *MockStakingKeeperMockRecorder) GetUnbondingDelegationsFromValidator(ctx, valAddr any) *gomock.Call

GetUnbondingDelegationsFromValidator indicates an expected call of GetUnbondingDelegationsFromValidator.

func (*MockStakingKeeperMockRecorder) GetValidator

func (mr *MockStakingKeeperMockRecorder) GetValidator(ctx, addr any) *gomock.Call

GetValidator indicates an expected call of GetValidator.

func (*MockStakingKeeperMockRecorder) GetValidatorByConsAddr

func (mr *MockStakingKeeperMockRecorder) GetValidatorByConsAddr(ctx, consAddr any) *gomock.Call

GetValidatorByConsAddr indicates an expected call of GetValidatorByConsAddr.

func (*MockStakingKeeperMockRecorder) IterateBondedValidatorsByPower

func (mr *MockStakingKeeperMockRecorder) IterateBondedValidatorsByPower(arg0, arg1 any) *gomock.Call

IterateBondedValidatorsByPower indicates an expected call of IterateBondedValidatorsByPower.

func (*MockStakingKeeperMockRecorder) IterateDelegations

func (mr *MockStakingKeeperMockRecorder) IterateDelegations(ctx, delegator, fn any) *gomock.Call

IterateDelegations indicates an expected call of IterateDelegations.

func (*MockStakingKeeperMockRecorder) Jail

func (mr *MockStakingKeeperMockRecorder) Jail(arg0, arg1 any) *gomock.Call

Jail indicates an expected call of Jail.

func (*MockStakingKeeperMockRecorder) MaxValidators

func (mr *MockStakingKeeperMockRecorder) MaxValidators(ctx any) *gomock.Call

MaxValidators indicates an expected call of MaxValidators.

func (*MockStakingKeeperMockRecorder) PowerReduction

func (mr *MockStakingKeeperMockRecorder) PowerReduction(ctx any) *gomock.Call

PowerReduction indicates an expected call of PowerReduction.

func (*MockStakingKeeperMockRecorder) SlashRedelegation

func (mr *MockStakingKeeperMockRecorder) SlashRedelegation(ctx, srcValidator, redelegation, infractionHeight, slashFactor any) *gomock.Call

SlashRedelegation indicates an expected call of SlashRedelegation.

func (*MockStakingKeeperMockRecorder) SlashUnbondingDelegation

func (mr *MockStakingKeeperMockRecorder) SlashUnbondingDelegation(ctx, unbondingDelegation, infractionHeight, slashFactor any) *gomock.Call

SlashUnbondingDelegation indicates an expected call of SlashUnbondingDelegation.

func (*MockStakingKeeperMockRecorder) SlashWithInfractionReason

func (mr *MockStakingKeeperMockRecorder) SlashWithInfractionReason(ctx, consAddr, infractionHeight, power, slashFactor, infraction any) *gomock.Call

SlashWithInfractionReason indicates an expected call of SlashWithInfractionReason.

func (*MockStakingKeeperMockRecorder) StakingTokenSupply

func (mr *MockStakingKeeperMockRecorder) StakingTokenSupply(ctx any) *gomock.Call

StakingTokenSupply indicates an expected call of StakingTokenSupply.

func (*MockStakingKeeperMockRecorder) TotalBondedTokens

func (mr *MockStakingKeeperMockRecorder) TotalBondedTokens(ctx any) *gomock.Call

TotalBondedTokens indicates an expected call of TotalBondedTokens.

func (*MockStakingKeeperMockRecorder) UnbondingCanComplete

func (mr *MockStakingKeeperMockRecorder) UnbondingCanComplete(ctx, id any) *gomock.Call

UnbondingCanComplete indicates an expected call of UnbondingCanComplete.

func (*MockStakingKeeperMockRecorder) UnbondingTime

func (mr *MockStakingKeeperMockRecorder) UnbondingTime(ctx any) *gomock.Call

UnbondingTime indicates an expected call of UnbondingTime.

func (*MockStakingKeeperMockRecorder) ValidatorAddressCodec

func (mr *MockStakingKeeperMockRecorder) ValidatorAddressCodec() *gomock.Call

ValidatorAddressCodec indicates an expected call of ValidatorAddressCodec.

type MockedKeepers

A struct holding pointers to any mocked external keeper needed for provider/consumer keeper setup.

func GetConsumerKeeperAndCtx

func GetConsumerKeeperAndCtx(t *testing.T, params InMemKeeperParams) (
	consumerkeeper.Keeper, sdk.Context, *gomock.Controller, MockedKeepers,
)

Return an in-memory consumer keeper, context, controller, and mocks, given a test instance and parameters.

Note: Calling ctrl.Finish() at the end of a test function ensures that no unexpected calls to external keepers are made.

func GetProviderKeeperAndCtx

func GetProviderKeeperAndCtx(t *testing.T, params InMemKeeperParams) (
	providerkeeper.Keeper, sdk.Context, *gomock.Controller, MockedKeepers,
)

Returns an in-memory provider keeper, context, controller, and mocks, given a test instance and parameters.

Note: Calling ctrl.Finish() at the end of a test function ensures that no unexpected calls to external keepers are made.

func NewMockedKeepers

func NewMockedKeepers(ctrl *gomock.Controller) MockedKeepers

NewMockedKeepers instantiates a struct with pointers to properly instantiated mocked keepers.

Jump to

Keyboard shortcuts

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