erigon-pulse/polygon/sync/mock/heimdall_mock.go
milen 64072ce6c7
polygon/sync: implement header downloader (#9030)
Co-authored-by: battlmonstr <battlmonstr@users.noreply.github.com>
2023-12-22 10:44:55 +00:00

98 lines
3.5 KiB
Go

// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/ledgerwatch/erigon/polygon/sync (interfaces: Heimdall)
// Package mock is a generated GoMock package.
package mock
import (
context "context"
reflect "reflect"
gomock "github.com/golang/mock/gomock"
checkpoint "github.com/ledgerwatch/erigon/consensus/bor/heimdall/checkpoint"
milestone "github.com/ledgerwatch/erigon/consensus/bor/heimdall/milestone"
span "github.com/ledgerwatch/erigon/consensus/bor/heimdall/span"
)
// MockHeimdall is a mock of Heimdall interface.
type MockHeimdall struct {
ctrl *gomock.Controller
recorder *MockHeimdallMockRecorder
}
// MockHeimdallMockRecorder is the mock recorder for MockHeimdall.
type MockHeimdallMockRecorder struct {
mock *MockHeimdall
}
// NewMockHeimdall creates a new mock instance.
func NewMockHeimdall(ctrl *gomock.Controller) *MockHeimdall {
mock := &MockHeimdall{ctrl: ctrl}
mock.recorder = &MockHeimdallMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockHeimdall) EXPECT() *MockHeimdallMockRecorder {
return m.recorder
}
// FetchCheckpoints mocks base method.
func (m *MockHeimdall) FetchCheckpoints(arg0 context.Context, arg1 uint64) ([]*checkpoint.Checkpoint, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FetchCheckpoints", arg0, arg1)
ret0, _ := ret[0].([]*checkpoint.Checkpoint)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// FetchCheckpoints indicates an expected call of FetchCheckpoints.
func (mr *MockHeimdallMockRecorder) FetchCheckpoints(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FetchCheckpoints", reflect.TypeOf((*MockHeimdall)(nil).FetchCheckpoints), arg0, arg1)
}
// FetchMilestones mocks base method.
func (m *MockHeimdall) FetchMilestones(arg0 context.Context, arg1 uint64) ([]*milestone.Milestone, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FetchMilestones", arg0, arg1)
ret0, _ := ret[0].([]*milestone.Milestone)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// FetchMilestones indicates an expected call of FetchMilestones.
func (mr *MockHeimdallMockRecorder) FetchMilestones(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FetchMilestones", reflect.TypeOf((*MockHeimdall)(nil).FetchMilestones), arg0, arg1)
}
// FetchSpan mocks base method.
func (m *MockHeimdall) FetchSpan(arg0 context.Context, arg1 uint64) (*span.HeimdallSpan, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FetchSpan", arg0, arg1)
ret0, _ := ret[0].(*span.HeimdallSpan)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// FetchSpan indicates an expected call of FetchSpan.
func (mr *MockHeimdallMockRecorder) FetchSpan(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FetchSpan", reflect.TypeOf((*MockHeimdall)(nil).FetchSpan), arg0, arg1)
}
// OnMilestoneEvent mocks base method.
func (m *MockHeimdall) OnMilestoneEvent(arg0 context.Context, arg1 func(*milestone.Milestone)) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "OnMilestoneEvent", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// OnMilestoneEvent indicates an expected call of OnMilestoneEvent.
func (mr *MockHeimdallMockRecorder) OnMilestoneEvent(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OnMilestoneEvent", reflect.TypeOf((*MockHeimdall)(nil).OnMilestoneEvent), arg0, arg1)
}