github.com/iotexproject/iotex-core@v1.14.1-rc1/test/mock/mock_blocksync/mock_blocksync.go (about)

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: ./blocksync/blocksync.go
     3  
     4  // Package mock_blocksync is a generated GoMock package.
     5  package mock_blocksync
     6  
     7  import (
     8  	context "context"
     9  	reflect "reflect"
    10  
    11  	gomock "github.com/golang/mock/gomock"
    12  	block "github.com/iotexproject/iotex-core/blockchain/block"
    13  	peer "github.com/libp2p/go-libp2p-core/peer"
    14  )
    15  
    16  // MockBlockSync is a mock of BlockSync interface.
    17  type MockBlockSync struct {
    18  	ctrl     *gomock.Controller
    19  	recorder *MockBlockSyncMockRecorder
    20  }
    21  
    22  // MockBlockSyncMockRecorder is the mock recorder for MockBlockSync.
    23  type MockBlockSyncMockRecorder struct {
    24  	mock *MockBlockSync
    25  }
    26  
    27  // NewMockBlockSync creates a new mock instance.
    28  func NewMockBlockSync(ctrl *gomock.Controller) *MockBlockSync {
    29  	mock := &MockBlockSync{ctrl: ctrl}
    30  	mock.recorder = &MockBlockSyncMockRecorder{mock}
    31  	return mock
    32  }
    33  
    34  // EXPECT returns an object that allows the caller to indicate expected use.
    35  func (m *MockBlockSync) EXPECT() *MockBlockSyncMockRecorder {
    36  	return m.recorder
    37  }
    38  
    39  // BuildReport mocks base method.
    40  func (m *MockBlockSync) BuildReport() string {
    41  	m.ctrl.T.Helper()
    42  	ret := m.ctrl.Call(m, "BuildReport")
    43  	ret0, _ := ret[0].(string)
    44  	return ret0
    45  }
    46  
    47  // BuildReport indicates an expected call of BuildReport.
    48  func (mr *MockBlockSyncMockRecorder) BuildReport() *gomock.Call {
    49  	mr.mock.ctrl.T.Helper()
    50  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BuildReport", reflect.TypeOf((*MockBlockSync)(nil).BuildReport))
    51  }
    52  
    53  // ProcessBlock mocks base method.
    54  func (m *MockBlockSync) ProcessBlock(arg0 context.Context, arg1 string, arg2 *block.Block) error {
    55  	m.ctrl.T.Helper()
    56  	ret := m.ctrl.Call(m, "ProcessBlock", arg0, arg1, arg2)
    57  	ret0, _ := ret[0].(error)
    58  	return ret0
    59  }
    60  
    61  // ProcessBlock indicates an expected call of ProcessBlock.
    62  func (mr *MockBlockSyncMockRecorder) ProcessBlock(arg0, arg1, arg2 interface{}) *gomock.Call {
    63  	mr.mock.ctrl.T.Helper()
    64  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ProcessBlock", reflect.TypeOf((*MockBlockSync)(nil).ProcessBlock), arg0, arg1, arg2)
    65  }
    66  
    67  // ProcessSyncRequest mocks base method.
    68  func (m *MockBlockSync) ProcessSyncRequest(arg0 context.Context, arg1 peer.AddrInfo, arg2, arg3 uint64) error {
    69  	m.ctrl.T.Helper()
    70  	ret := m.ctrl.Call(m, "ProcessSyncRequest", arg0, arg1, arg2, arg3)
    71  	ret0, _ := ret[0].(error)
    72  	return ret0
    73  }
    74  
    75  // ProcessSyncRequest indicates an expected call of ProcessSyncRequest.
    76  func (mr *MockBlockSyncMockRecorder) ProcessSyncRequest(arg0, arg1, arg2, arg3 interface{}) *gomock.Call {
    77  	mr.mock.ctrl.T.Helper()
    78  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ProcessSyncRequest", reflect.TypeOf((*MockBlockSync)(nil).ProcessSyncRequest), arg0, arg1, arg2, arg3)
    79  }
    80  
    81  // Start mocks base method.
    82  func (m *MockBlockSync) Start(arg0 context.Context) error {
    83  	m.ctrl.T.Helper()
    84  	ret := m.ctrl.Call(m, "Start", arg0)
    85  	ret0, _ := ret[0].(error)
    86  	return ret0
    87  }
    88  
    89  // Start indicates an expected call of Start.
    90  func (mr *MockBlockSyncMockRecorder) Start(arg0 interface{}) *gomock.Call {
    91  	mr.mock.ctrl.T.Helper()
    92  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Start", reflect.TypeOf((*MockBlockSync)(nil).Start), arg0)
    93  }
    94  
    95  // Stop mocks base method.
    96  func (m *MockBlockSync) Stop(arg0 context.Context) error {
    97  	m.ctrl.T.Helper()
    98  	ret := m.ctrl.Call(m, "Stop", arg0)
    99  	ret0, _ := ret[0].(error)
   100  	return ret0
   101  }
   102  
   103  // Stop indicates an expected call of Stop.
   104  func (mr *MockBlockSyncMockRecorder) Stop(arg0 interface{}) *gomock.Call {
   105  	mr.mock.ctrl.T.Helper()
   106  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stop", reflect.TypeOf((*MockBlockSync)(nil).Stop), arg0)
   107  }
   108  
   109  // SyncStatus mocks base method.
   110  func (m *MockBlockSync) SyncStatus() (uint64, uint64, uint64, string) {
   111  	m.ctrl.T.Helper()
   112  	ret := m.ctrl.Call(m, "SyncStatus")
   113  	ret0, _ := ret[0].(uint64)
   114  	ret1, _ := ret[1].(uint64)
   115  	ret2, _ := ret[2].(uint64)
   116  	ret3, _ := ret[3].(string)
   117  	return ret0, ret1, ret2, ret3
   118  }
   119  
   120  // SyncStatus indicates an expected call of SyncStatus.
   121  func (mr *MockBlockSyncMockRecorder) SyncStatus() *gomock.Call {
   122  	mr.mock.ctrl.T.Helper()
   123  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SyncStatus", reflect.TypeOf((*MockBlockSync)(nil).SyncStatus))
   124  }
   125  
   126  // TargetHeight mocks base method.
   127  func (m *MockBlockSync) TargetHeight() uint64 {
   128  	m.ctrl.T.Helper()
   129  	ret := m.ctrl.Call(m, "TargetHeight")
   130  	ret0, _ := ret[0].(uint64)
   131  	return ret0
   132  }
   133  
   134  // TargetHeight indicates an expected call of TargetHeight.
   135  func (mr *MockBlockSyncMockRecorder) TargetHeight() *gomock.Call {
   136  	mr.mock.ctrl.T.Helper()
   137  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TargetHeight", reflect.TypeOf((*MockBlockSync)(nil).TargetHeight))
   138  }