mocks

package
v0.0.0-...-7ece11e Latest Latest
Warning

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

Go to latest
Published: Aug 29, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chain

type Chain struct {
	mock.Mock
}

Chain is an autogenerated mock type for the Chain type

func (*Chain) BestViewCommitteeFromBlock

func (_m *Chain) BestViewCommitteeFromBlock() common.Hash

BestViewCommitteeFromBlock provides a mock function with given fields:

func (*Chain) CommitteeEngineVersion

func (_m *Chain) CommitteeEngineVersion() int

CommitteeEngineVersion provides a mock function with given fields:

func (*Chain) CommitteesFromViewHashForShard

func (_m *Chain) CommitteesFromViewHashForShard(committeeHash common.Hash, shardID byte) ([]incognitokey.CommitteePublicKey, error)

CommitteesFromViewHashForShard provides a mock function with given fields: committeeHash, shardID

func (*Chain) CreateNewBlock

func (_m *Chain) CreateNewBlock(version int, proposer string, round int, startTime int64, committees []incognitokey.CommitteePublicKey, hash common.Hash) (types.BlockInterface, error)

CreateNewBlock provides a mock function with given fields: version, proposer, round, startTime, committees, hash

func (*Chain) CreateNewBlockFromOldBlock

func (_m *Chain) CreateNewBlockFromOldBlock(oldBlock types.BlockInterface, proposer string, startTime int64, committees []incognitokey.CommitteePublicKey, hash common.Hash) (types.BlockInterface, error)

CreateNewBlockFromOldBlock provides a mock function with given fields: oldBlock, proposer, startTime, committees, hash

func (*Chain) CurrentHeight

func (_m *Chain) CurrentHeight() uint64

CurrentHeight provides a mock function with given fields:

func (*Chain) GetActiveShardNumber

func (_m *Chain) GetActiveShardNumber() int

GetActiveShardNumber provides a mock function with given fields:

func (*Chain) GetBestView

func (_m *Chain) GetBestView() multiview.View

GetBestView provides a mock function with given fields:

func (*Chain) GetBestViewHash

func (_m *Chain) GetBestViewHash() string

GetBestViewHash provides a mock function with given fields:

func (*Chain) GetBestViewHeight

func (_m *Chain) GetBestViewHeight() uint64

GetBestViewHeight provides a mock function with given fields:

func (*Chain) GetChainDatabase

func (_m *Chain) GetChainDatabase() incdb.Database

GetChainDatabase provides a mock function with given fields:

func (*Chain) GetChainName

func (_m *Chain) GetChainName() string

GetChainName provides a mock function with given fields:

func (*Chain) GetCommittee

func (_m *Chain) GetCommittee() []incognitokey.CommitteePublicKey

GetCommittee provides a mock function with given fields:

func (*Chain) GetCommitteeSize

func (_m *Chain) GetCommitteeSize() int

GetCommitteeSize provides a mock function with given fields:

func (*Chain) GetConsensusType

func (_m *Chain) GetConsensusType() string

GetConsensusType provides a mock function with given fields:

func (*Chain) GetEpoch

func (_m *Chain) GetEpoch() uint64

GetEpoch provides a mock function with given fields:

func (*Chain) GetFinalView

func (_m *Chain) GetFinalView() multiview.View

GetFinalView provides a mock function with given fields:

func (*Chain) GetFinalViewHash

func (_m *Chain) GetFinalViewHash() string

GetFinalViewHash provides a mock function with given fields:

func (*Chain) GetFinalViewHeight

func (_m *Chain) GetFinalViewHeight() uint64

GetFinalViewHeight provides a mock function with given fields:

func (*Chain) GetLastBlockTimeStamp

func (_m *Chain) GetLastBlockTimeStamp() int64

GetLastBlockTimeStamp provides a mock function with given fields:

func (*Chain) GetLastProposerIndex

func (_m *Chain) GetLastProposerIndex() int

GetLastProposerIndex provides a mock function with given fields:

func (*Chain) GetMaxBlkCreateTime

func (_m *Chain) GetMaxBlkCreateTime() time.Duration

GetMaxBlkCreateTime provides a mock function with given fields:

func (*Chain) GetMinBlkInterval

func (_m *Chain) GetMinBlkInterval() time.Duration

GetMinBlkInterval provides a mock function with given fields:

func (*Chain) GetPendingCommittee

func (_m *Chain) GetPendingCommittee() []incognitokey.CommitteePublicKey

GetPendingCommittee provides a mock function with given fields:

func (*Chain) GetProposerByTimeSlot

func (_m *Chain) GetProposerByTimeSlot(committeeViewHash common.Hash, shardID byte, ts int64, committees []incognitokey.CommitteePublicKey) (incognitokey.CommitteePublicKey, int, error)

GetProposerByTimeSlot provides a mock function with given fields: committeeViewHash, shardID, ts, committees

func (*Chain) GetPubKeyCommitteeIndex

func (_m *Chain) GetPubKeyCommitteeIndex(_a0 string) int

GetPubKeyCommitteeIndex provides a mock function with given fields: _a0

func (*Chain) GetShardID

func (_m *Chain) GetShardID() int

GetShardID provides a mock function with given fields:

func (*Chain) GetSigningCommitteesFromBestView

func (_m *Chain) GetSigningCommitteesFromBestView(committeeViewHash common.Hash, proposerIndex int, committees []incognitokey.CommitteePublicKey, shardID byte) []incognitokey.CommitteePublicKey

SigningCommittees provides a mock function with given fields: committeeViewHash, proposerIndex, committees, shardID

func (*Chain) GetViewByHash

func (_m *Chain) GetViewByHash(hash common.Hash) multiview.View

GetViewByHash provides a mock function with given fields: hash

func (*Chain) InsertBlock

func (_m *Chain) InsertBlock(block types.BlockInterface, shouldValidate bool) error

InsertBlock provides a mock function with given fields: block, shouldValidate

func (*Chain) IsBeaconChain

func (_m *Chain) IsBeaconChain() bool

IsBeaconChain provides a mock function with given fields:

func (*Chain) IsReady

func (_m *Chain) IsReady() bool

IsReady provides a mock function with given fields:

func (*Chain) ReplacePreviousValidationData

func (_m *Chain) ReplacePreviousValidationData(previousBlockHash common.Hash, newValidationData string) error

ReplacePreviousValidationData provides a mock function with given fields: previousBlockHash, newValidationData

func (*Chain) SetReady

func (_m *Chain) SetReady(_a0 bool)

SetReady provides a mock function with given fields: _a0

func (*Chain) UnmarshalBlock

func (_m *Chain) UnmarshalBlock(blockString []byte) (types.BlockInterface, error)

UnmarshalBlock provides a mock function with given fields: blockString

func (*Chain) ValidateBlockSignatures

func (_m *Chain) ValidateBlockSignatures(block types.BlockInterface, committees []incognitokey.CommitteePublicKey) error

ValidateBlockSignatures provides a mock function with given fields: block, committees

func (*Chain) ValidatePreSignBlock

func (_m *Chain) ValidatePreSignBlock(block types.BlockInterface, signingCommittees []incognitokey.CommitteePublicKey, committees []incognitokey.CommitteePublicKey) error

ValidatePreSignBlock provides a mock function with given fields: block, signingCommittees, committees

Jump to

Keyboard shortcuts

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