Documentation ¶
Overview ¶
Package mock_consensus is a generated GoMock package.
Package mock_consensus is a generated GoMock package.
Index ¶
- type MockChainReader
- func (m *MockChainReader) Config() *config.QuarkChainConfig
- func (m *MockChainReader) CurrentHeader() types.IHeader
- func (m *MockChainReader) EXPECT() *MockChainReaderMockRecorder
- func (m *MockChainReader) GetBlock(hash common.Hash) types.IBlock
- func (m *MockChainReader) GetHeader(hash common.Hash) types.IHeader
- func (m *MockChainReader) GetHeaderByNumber(number uint64) types.IHeader
- type MockChainReaderMockRecorder
- func (mr *MockChainReaderMockRecorder) Config() *gomock.Call
- func (mr *MockChainReaderMockRecorder) CurrentHeader() *gomock.Call
- func (mr *MockChainReaderMockRecorder) GetBlock(hash interface{}) *gomock.Call
- func (mr *MockChainReaderMockRecorder) GetHeader(hash interface{}) *gomock.Call
- func (mr *MockChainReaderMockRecorder) GetHeaderByNumber(number interface{}) *gomock.Call
- type MockEngine
- func (m *MockEngine) Author(header types.IHeader) (account.Address, error)
- func (m *MockEngine) CalcDifficulty(chain consensus.ChainReader, time uint64, parent types.IHeader) *big.Int
- func (m *MockEngine) Close() error
- func (m *MockEngine) EXPECT() *MockEngineMockRecorder
- func (m *MockEngine) Prepare(chain consensus.ChainReader, header types.IHeader) error
- func (m *MockEngine) Seal(chain consensus.ChainReader, block types.IBlock, results chan<- types.IBlock, ...) error
- func (m *MockEngine) VerifyHeader(chain consensus.ChainReader, header types.IHeader, seal bool) error
- func (m *MockEngine) VerifyHeaders(chain consensus.ChainReader, headers []types.IHeader, seals []bool) (chan<- struct{}, <-chan error)
- func (m *MockEngine) VerifySeal(chain consensus.ChainReader, header types.IHeader, adjustedDiff *big.Int) error
- type MockEngineMockRecorder
- func (mr *MockEngineMockRecorder) Author(header interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) CalcDifficulty(chain, time, parent interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) Close() *gomock.Call
- func (mr *MockEngineMockRecorder) Prepare(chain, header interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) Seal(chain, block, results, stop interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) VerifyHeader(chain, header, seal interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) VerifyHeaders(chain, headers, seals interface{}) *gomock.Call
- func (mr *MockEngineMockRecorder) VerifySeal(chain, header, adjustedDiff interface{}) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockChainReader ¶
type MockChainReader struct {
// contains filtered or unexported fields
}
MockChainReader is a mock of ChainReader interface
func NewMockChainReader ¶
func NewMockChainReader(ctrl *gomock.Controller) *MockChainReader
NewMockChainReader creates a new mock instance
func (*MockChainReader) Config ¶
func (m *MockChainReader) Config() *config.QuarkChainConfig
Config mocks base method
func (*MockChainReader) CurrentHeader ¶
func (m *MockChainReader) CurrentHeader() types.IHeader
CurrentHeader mocks base method
func (*MockChainReader) EXPECT ¶
func (m *MockChainReader) EXPECT() *MockChainReaderMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockChainReader) GetBlock ¶
func (m *MockChainReader) GetBlock(hash common.Hash) types.IBlock
GetBlock mocks base method
func (*MockChainReader) GetHeader ¶
func (m *MockChainReader) GetHeader(hash common.Hash) types.IHeader
GetHeader mocks base method
func (*MockChainReader) GetHeaderByNumber ¶
func (m *MockChainReader) GetHeaderByNumber(number uint64) types.IHeader
GetHeaderByNumber mocks base method
type MockChainReaderMockRecorder ¶
type MockChainReaderMockRecorder struct {
// contains filtered or unexported fields
}
MockChainReaderMockRecorder is the mock recorder for MockChainReader
func (*MockChainReaderMockRecorder) Config ¶
func (mr *MockChainReaderMockRecorder) Config() *gomock.Call
Config indicates an expected call of Config
func (*MockChainReaderMockRecorder) CurrentHeader ¶
func (mr *MockChainReaderMockRecorder) CurrentHeader() *gomock.Call
CurrentHeader indicates an expected call of CurrentHeader
func (*MockChainReaderMockRecorder) GetBlock ¶
func (mr *MockChainReaderMockRecorder) GetBlock(hash interface{}) *gomock.Call
GetBlock indicates an expected call of GetBlock
func (*MockChainReaderMockRecorder) GetHeader ¶
func (mr *MockChainReaderMockRecorder) GetHeader(hash interface{}) *gomock.Call
GetHeader indicates an expected call of GetHeader
func (*MockChainReaderMockRecorder) GetHeaderByNumber ¶
func (mr *MockChainReaderMockRecorder) GetHeaderByNumber(number interface{}) *gomock.Call
GetHeaderByNumber indicates an expected call of GetHeaderByNumber
type MockEngine ¶
type MockEngine struct {
// contains filtered or unexported fields
}
MockEngine is a mock of Engine interface
func NewMockEngine ¶
func NewMockEngine(ctrl *gomock.Controller) *MockEngine
NewMockEngine creates a new mock instance
func (*MockEngine) CalcDifficulty ¶
func (m *MockEngine) CalcDifficulty(chain consensus.ChainReader, time uint64, parent types.IHeader) *big.Int
CalcDifficulty mocks base method
func (*MockEngine) EXPECT ¶
func (m *MockEngine) EXPECT() *MockEngineMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*MockEngine) Prepare ¶
func (m *MockEngine) Prepare(chain consensus.ChainReader, header types.IHeader) error
Prepare mocks base method
func (*MockEngine) Seal ¶
func (m *MockEngine) Seal(chain consensus.ChainReader, block types.IBlock, results chan<- types.IBlock, stop <-chan struct{}) error
Seal mocks base method
func (*MockEngine) VerifyHeader ¶
func (m *MockEngine) VerifyHeader(chain consensus.ChainReader, header types.IHeader, seal bool) error
VerifyHeader mocks base method
func (*MockEngine) VerifyHeaders ¶
func (m *MockEngine) VerifyHeaders(chain consensus.ChainReader, headers []types.IHeader, seals []bool) (chan<- struct{}, <-chan error)
VerifyHeaders mocks base method
func (*MockEngine) VerifySeal ¶
func (m *MockEngine) VerifySeal(chain consensus.ChainReader, header types.IHeader, adjustedDiff *big.Int) error
VerifySeal mocks base method
type MockEngineMockRecorder ¶
type MockEngineMockRecorder struct {
// contains filtered or unexported fields
}
MockEngineMockRecorder is the mock recorder for MockEngine
func (*MockEngineMockRecorder) Author ¶
func (mr *MockEngineMockRecorder) Author(header interface{}) *gomock.Call
Author indicates an expected call of Author
func (*MockEngineMockRecorder) CalcDifficulty ¶
func (mr *MockEngineMockRecorder) CalcDifficulty(chain, time, parent interface{}) *gomock.Call
CalcDifficulty indicates an expected call of CalcDifficulty
func (*MockEngineMockRecorder) Close ¶
func (mr *MockEngineMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close
func (*MockEngineMockRecorder) Prepare ¶
func (mr *MockEngineMockRecorder) Prepare(chain, header interface{}) *gomock.Call
Prepare indicates an expected call of Prepare
func (*MockEngineMockRecorder) Seal ¶
func (mr *MockEngineMockRecorder) Seal(chain, block, results, stop interface{}) *gomock.Call
Seal indicates an expected call of Seal
func (*MockEngineMockRecorder) VerifyHeader ¶
func (mr *MockEngineMockRecorder) VerifyHeader(chain, header, seal interface{}) *gomock.Call
VerifyHeader indicates an expected call of VerifyHeader
func (*MockEngineMockRecorder) VerifyHeaders ¶
func (mr *MockEngineMockRecorder) VerifyHeaders(chain, headers, seals interface{}) *gomock.Call
VerifyHeaders indicates an expected call of VerifyHeaders
func (*MockEngineMockRecorder) VerifySeal ¶
func (mr *MockEngineMockRecorder) VerifySeal(chain, header, adjustedDiff interface{}) *gomock.Call
VerifySeal indicates an expected call of VerifySeal