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

     1  // Code generated by MockGen. DO NOT EDIT.
     2  // Source: ./action/protocol/managers.go
     3  
     4  // Package mock_chainmanager is a generated GoMock package.
     5  package mock_chainmanager
     6  
     7  import (
     8  	reflect "reflect"
     9  
    10  	gomock "github.com/golang/mock/gomock"
    11  	protocol "github.com/iotexproject/iotex-core/action/protocol"
    12  	state "github.com/iotexproject/iotex-core/state"
    13  )
    14  
    15  // MockStateReader is a mock of StateReader interface.
    16  type MockStateReader struct {
    17  	ctrl     *gomock.Controller
    18  	recorder *MockStateReaderMockRecorder
    19  }
    20  
    21  // MockStateReaderMockRecorder is the mock recorder for MockStateReader.
    22  type MockStateReaderMockRecorder struct {
    23  	mock *MockStateReader
    24  }
    25  
    26  // NewMockStateReader creates a new mock instance.
    27  func NewMockStateReader(ctrl *gomock.Controller) *MockStateReader {
    28  	mock := &MockStateReader{ctrl: ctrl}
    29  	mock.recorder = &MockStateReaderMockRecorder{mock}
    30  	return mock
    31  }
    32  
    33  // EXPECT returns an object that allows the caller to indicate expected use.
    34  func (m *MockStateReader) EXPECT() *MockStateReaderMockRecorder {
    35  	return m.recorder
    36  }
    37  
    38  // Height mocks base method.
    39  func (m *MockStateReader) Height() (uint64, error) {
    40  	m.ctrl.T.Helper()
    41  	ret := m.ctrl.Call(m, "Height")
    42  	ret0, _ := ret[0].(uint64)
    43  	ret1, _ := ret[1].(error)
    44  	return ret0, ret1
    45  }
    46  
    47  // Height indicates an expected call of Height.
    48  func (mr *MockStateReaderMockRecorder) Height() *gomock.Call {
    49  	mr.mock.ctrl.T.Helper()
    50  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Height", reflect.TypeOf((*MockStateReader)(nil).Height))
    51  }
    52  
    53  // ReadView mocks base method.
    54  func (m *MockStateReader) ReadView(arg0 string) (interface{}, error) {
    55  	m.ctrl.T.Helper()
    56  	ret := m.ctrl.Call(m, "ReadView", arg0)
    57  	ret0, _ := ret[0].(interface{})
    58  	ret1, _ := ret[1].(error)
    59  	return ret0, ret1
    60  }
    61  
    62  // ReadView indicates an expected call of ReadView.
    63  func (mr *MockStateReaderMockRecorder) ReadView(arg0 interface{}) *gomock.Call {
    64  	mr.mock.ctrl.T.Helper()
    65  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadView", reflect.TypeOf((*MockStateReader)(nil).ReadView), arg0)
    66  }
    67  
    68  // State mocks base method.
    69  func (m *MockStateReader) State(arg0 interface{}, arg1 ...protocol.StateOption) (uint64, error) {
    70  	m.ctrl.T.Helper()
    71  	varargs := []interface{}{arg0}
    72  	for _, a := range arg1 {
    73  		varargs = append(varargs, a)
    74  	}
    75  	ret := m.ctrl.Call(m, "State", varargs...)
    76  	ret0, _ := ret[0].(uint64)
    77  	ret1, _ := ret[1].(error)
    78  	return ret0, ret1
    79  }
    80  
    81  // State indicates an expected call of State.
    82  func (mr *MockStateReaderMockRecorder) State(arg0 interface{}, arg1 ...interface{}) *gomock.Call {
    83  	mr.mock.ctrl.T.Helper()
    84  	varargs := append([]interface{}{arg0}, arg1...)
    85  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "State", reflect.TypeOf((*MockStateReader)(nil).State), varargs...)
    86  }
    87  
    88  // States mocks base method.
    89  func (m *MockStateReader) States(arg0 ...protocol.StateOption) (uint64, state.Iterator, error) {
    90  	m.ctrl.T.Helper()
    91  	varargs := []interface{}{}
    92  	for _, a := range arg0 {
    93  		varargs = append(varargs, a)
    94  	}
    95  	ret := m.ctrl.Call(m, "States", varargs...)
    96  	ret0, _ := ret[0].(uint64)
    97  	ret1, _ := ret[1].(state.Iterator)
    98  	ret2, _ := ret[2].(error)
    99  	return ret0, ret1, ret2
   100  }
   101  
   102  // States indicates an expected call of States.
   103  func (mr *MockStateReaderMockRecorder) States(arg0 ...interface{}) *gomock.Call {
   104  	mr.mock.ctrl.T.Helper()
   105  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "States", reflect.TypeOf((*MockStateReader)(nil).States), arg0...)
   106  }
   107  
   108  // MockStateManager is a mock of StateManager interface.
   109  type MockStateManager struct {
   110  	ctrl     *gomock.Controller
   111  	recorder *MockStateManagerMockRecorder
   112  }
   113  
   114  // MockStateManagerMockRecorder is the mock recorder for MockStateManager.
   115  type MockStateManagerMockRecorder struct {
   116  	mock *MockStateManager
   117  }
   118  
   119  // NewMockStateManager creates a new mock instance.
   120  func NewMockStateManager(ctrl *gomock.Controller) *MockStateManager {
   121  	mock := &MockStateManager{ctrl: ctrl}
   122  	mock.recorder = &MockStateManagerMockRecorder{mock}
   123  	return mock
   124  }
   125  
   126  // EXPECT returns an object that allows the caller to indicate expected use.
   127  func (m *MockStateManager) EXPECT() *MockStateManagerMockRecorder {
   128  	return m.recorder
   129  }
   130  
   131  // DelState mocks base method.
   132  func (m *MockStateManager) DelState(arg0 ...protocol.StateOption) (uint64, error) {
   133  	m.ctrl.T.Helper()
   134  	varargs := []interface{}{}
   135  	for _, a := range arg0 {
   136  		varargs = append(varargs, a)
   137  	}
   138  	ret := m.ctrl.Call(m, "DelState", varargs...)
   139  	ret0, _ := ret[0].(uint64)
   140  	ret1, _ := ret[1].(error)
   141  	return ret0, ret1
   142  }
   143  
   144  // DelState indicates an expected call of DelState.
   145  func (mr *MockStateManagerMockRecorder) DelState(arg0 ...interface{}) *gomock.Call {
   146  	mr.mock.ctrl.T.Helper()
   147  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DelState", reflect.TypeOf((*MockStateManager)(nil).DelState), arg0...)
   148  }
   149  
   150  // Height mocks base method.
   151  func (m *MockStateManager) Height() (uint64, error) {
   152  	m.ctrl.T.Helper()
   153  	ret := m.ctrl.Call(m, "Height")
   154  	ret0, _ := ret[0].(uint64)
   155  	ret1, _ := ret[1].(error)
   156  	return ret0, ret1
   157  }
   158  
   159  // Height indicates an expected call of Height.
   160  func (mr *MockStateManagerMockRecorder) Height() *gomock.Call {
   161  	mr.mock.ctrl.T.Helper()
   162  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Height", reflect.TypeOf((*MockStateManager)(nil).Height))
   163  }
   164  
   165  // Load mocks base method.
   166  func (m *MockStateManager) Load(arg0, arg1 string, arg2 interface{}) error {
   167  	m.ctrl.T.Helper()
   168  	ret := m.ctrl.Call(m, "Load", arg0, arg1, arg2)
   169  	ret0, _ := ret[0].(error)
   170  	return ret0
   171  }
   172  
   173  // Load indicates an expected call of Load.
   174  func (mr *MockStateManagerMockRecorder) Load(arg0, arg1, arg2 interface{}) *gomock.Call {
   175  	mr.mock.ctrl.T.Helper()
   176  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Load", reflect.TypeOf((*MockStateManager)(nil).Load), arg0, arg1, arg2)
   177  }
   178  
   179  // ProtocolDirty mocks base method.
   180  func (m *MockStateManager) ProtocolDirty(arg0 string) bool {
   181  	m.ctrl.T.Helper()
   182  	ret := m.ctrl.Call(m, "ProtocolDirty", arg0)
   183  	ret0, _ := ret[0].(bool)
   184  	return ret0
   185  }
   186  
   187  // ProtocolDirty indicates an expected call of ProtocolDirty.
   188  func (mr *MockStateManagerMockRecorder) ProtocolDirty(arg0 interface{}) *gomock.Call {
   189  	mr.mock.ctrl.T.Helper()
   190  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ProtocolDirty", reflect.TypeOf((*MockStateManager)(nil).ProtocolDirty), arg0)
   191  }
   192  
   193  // PutState mocks base method.
   194  func (m *MockStateManager) PutState(arg0 interface{}, arg1 ...protocol.StateOption) (uint64, error) {
   195  	m.ctrl.T.Helper()
   196  	varargs := []interface{}{arg0}
   197  	for _, a := range arg1 {
   198  		varargs = append(varargs, a)
   199  	}
   200  	ret := m.ctrl.Call(m, "PutState", varargs...)
   201  	ret0, _ := ret[0].(uint64)
   202  	ret1, _ := ret[1].(error)
   203  	return ret0, ret1
   204  }
   205  
   206  // PutState indicates an expected call of PutState.
   207  func (mr *MockStateManagerMockRecorder) PutState(arg0 interface{}, arg1 ...interface{}) *gomock.Call {
   208  	mr.mock.ctrl.T.Helper()
   209  	varargs := append([]interface{}{arg0}, arg1...)
   210  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutState", reflect.TypeOf((*MockStateManager)(nil).PutState), varargs...)
   211  }
   212  
   213  // ReadView mocks base method.
   214  func (m *MockStateManager) ReadView(arg0 string) (interface{}, error) {
   215  	m.ctrl.T.Helper()
   216  	ret := m.ctrl.Call(m, "ReadView", arg0)
   217  	ret0, _ := ret[0].(interface{})
   218  	ret1, _ := ret[1].(error)
   219  	return ret0, ret1
   220  }
   221  
   222  // ReadView indicates an expected call of ReadView.
   223  func (mr *MockStateManagerMockRecorder) ReadView(arg0 interface{}) *gomock.Call {
   224  	mr.mock.ctrl.T.Helper()
   225  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadView", reflect.TypeOf((*MockStateManager)(nil).ReadView), arg0)
   226  }
   227  
   228  // Reset mocks base method.
   229  func (m *MockStateManager) Reset() {
   230  	m.ctrl.T.Helper()
   231  	m.ctrl.Call(m, "Reset")
   232  }
   233  
   234  // Reset indicates an expected call of Reset.
   235  func (mr *MockStateManagerMockRecorder) Reset() *gomock.Call {
   236  	mr.mock.ctrl.T.Helper()
   237  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Reset", reflect.TypeOf((*MockStateManager)(nil).Reset))
   238  }
   239  
   240  // Revert mocks base method.
   241  func (m *MockStateManager) Revert(arg0 int) error {
   242  	m.ctrl.T.Helper()
   243  	ret := m.ctrl.Call(m, "Revert", arg0)
   244  	ret0, _ := ret[0].(error)
   245  	return ret0
   246  }
   247  
   248  // Revert indicates an expected call of Revert.
   249  func (mr *MockStateManagerMockRecorder) Revert(arg0 interface{}) *gomock.Call {
   250  	mr.mock.ctrl.T.Helper()
   251  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Revert", reflect.TypeOf((*MockStateManager)(nil).Revert), arg0)
   252  }
   253  
   254  // Snapshot mocks base method.
   255  func (m *MockStateManager) Snapshot() int {
   256  	m.ctrl.T.Helper()
   257  	ret := m.ctrl.Call(m, "Snapshot")
   258  	ret0, _ := ret[0].(int)
   259  	return ret0
   260  }
   261  
   262  // Snapshot indicates an expected call of Snapshot.
   263  func (mr *MockStateManagerMockRecorder) Snapshot() *gomock.Call {
   264  	mr.mock.ctrl.T.Helper()
   265  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Snapshot", reflect.TypeOf((*MockStateManager)(nil).Snapshot))
   266  }
   267  
   268  // State mocks base method.
   269  func (m *MockStateManager) State(arg0 interface{}, arg1 ...protocol.StateOption) (uint64, error) {
   270  	m.ctrl.T.Helper()
   271  	varargs := []interface{}{arg0}
   272  	for _, a := range arg1 {
   273  		varargs = append(varargs, a)
   274  	}
   275  	ret := m.ctrl.Call(m, "State", varargs...)
   276  	ret0, _ := ret[0].(uint64)
   277  	ret1, _ := ret[1].(error)
   278  	return ret0, ret1
   279  }
   280  
   281  // State indicates an expected call of State.
   282  func (mr *MockStateManagerMockRecorder) State(arg0 interface{}, arg1 ...interface{}) *gomock.Call {
   283  	mr.mock.ctrl.T.Helper()
   284  	varargs := append([]interface{}{arg0}, arg1...)
   285  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "State", reflect.TypeOf((*MockStateManager)(nil).State), varargs...)
   286  }
   287  
   288  // States mocks base method.
   289  func (m *MockStateManager) States(arg0 ...protocol.StateOption) (uint64, state.Iterator, error) {
   290  	m.ctrl.T.Helper()
   291  	varargs := []interface{}{}
   292  	for _, a := range arg0 {
   293  		varargs = append(varargs, a)
   294  	}
   295  	ret := m.ctrl.Call(m, "States", varargs...)
   296  	ret0, _ := ret[0].(uint64)
   297  	ret1, _ := ret[1].(state.Iterator)
   298  	ret2, _ := ret[2].(error)
   299  	return ret0, ret1, ret2
   300  }
   301  
   302  // States indicates an expected call of States.
   303  func (mr *MockStateManagerMockRecorder) States(arg0 ...interface{}) *gomock.Call {
   304  	mr.mock.ctrl.T.Helper()
   305  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "States", reflect.TypeOf((*MockStateManager)(nil).States), arg0...)
   306  }
   307  
   308  // Unload mocks base method.
   309  func (m *MockStateManager) Unload(arg0, arg1 string, arg2 interface{}) error {
   310  	m.ctrl.T.Helper()
   311  	ret := m.ctrl.Call(m, "Unload", arg0, arg1, arg2)
   312  	ret0, _ := ret[0].(error)
   313  	return ret0
   314  }
   315  
   316  // Unload indicates an expected call of Unload.
   317  func (mr *MockStateManagerMockRecorder) Unload(arg0, arg1, arg2 interface{}) *gomock.Call {
   318  	mr.mock.ctrl.T.Helper()
   319  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Unload", reflect.TypeOf((*MockStateManager)(nil).Unload), arg0, arg1, arg2)
   320  }
   321  
   322  // WriteView mocks base method.
   323  func (m *MockStateManager) WriteView(arg0 string, arg1 interface{}) error {
   324  	m.ctrl.T.Helper()
   325  	ret := m.ctrl.Call(m, "WriteView", arg0, arg1)
   326  	ret0, _ := ret[0].(error)
   327  	return ret0
   328  }
   329  
   330  // WriteView indicates an expected call of WriteView.
   331  func (mr *MockStateManagerMockRecorder) WriteView(arg0, arg1 interface{}) *gomock.Call {
   332  	mr.mock.ctrl.T.Helper()
   333  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WriteView", reflect.TypeOf((*MockStateManager)(nil).WriteView), arg0, arg1)
   334  }
   335  
   336  // MockDock is a mock of Dock interface.
   337  type MockDock struct {
   338  	ctrl     *gomock.Controller
   339  	recorder *MockDockMockRecorder
   340  }
   341  
   342  // MockDockMockRecorder is the mock recorder for MockDock.
   343  type MockDockMockRecorder struct {
   344  	mock *MockDock
   345  }
   346  
   347  // NewMockDock creates a new mock instance.
   348  func NewMockDock(ctrl *gomock.Controller) *MockDock {
   349  	mock := &MockDock{ctrl: ctrl}
   350  	mock.recorder = &MockDockMockRecorder{mock}
   351  	return mock
   352  }
   353  
   354  // EXPECT returns an object that allows the caller to indicate expected use.
   355  func (m *MockDock) EXPECT() *MockDockMockRecorder {
   356  	return m.recorder
   357  }
   358  
   359  // Load mocks base method.
   360  func (m *MockDock) Load(arg0, arg1 string, arg2 interface{}) error {
   361  	m.ctrl.T.Helper()
   362  	ret := m.ctrl.Call(m, "Load", arg0, arg1, arg2)
   363  	ret0, _ := ret[0].(error)
   364  	return ret0
   365  }
   366  
   367  // Load indicates an expected call of Load.
   368  func (mr *MockDockMockRecorder) Load(arg0, arg1, arg2 interface{}) *gomock.Call {
   369  	mr.mock.ctrl.T.Helper()
   370  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Load", reflect.TypeOf((*MockDock)(nil).Load), arg0, arg1, arg2)
   371  }
   372  
   373  // ProtocolDirty mocks base method.
   374  func (m *MockDock) ProtocolDirty(arg0 string) bool {
   375  	m.ctrl.T.Helper()
   376  	ret := m.ctrl.Call(m, "ProtocolDirty", arg0)
   377  	ret0, _ := ret[0].(bool)
   378  	return ret0
   379  }
   380  
   381  // ProtocolDirty indicates an expected call of ProtocolDirty.
   382  func (mr *MockDockMockRecorder) ProtocolDirty(arg0 interface{}) *gomock.Call {
   383  	mr.mock.ctrl.T.Helper()
   384  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ProtocolDirty", reflect.TypeOf((*MockDock)(nil).ProtocolDirty), arg0)
   385  }
   386  
   387  // Reset mocks base method.
   388  func (m *MockDock) Reset() {
   389  	m.ctrl.T.Helper()
   390  	m.ctrl.Call(m, "Reset")
   391  }
   392  
   393  // Reset indicates an expected call of Reset.
   394  func (mr *MockDockMockRecorder) Reset() *gomock.Call {
   395  	mr.mock.ctrl.T.Helper()
   396  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Reset", reflect.TypeOf((*MockDock)(nil).Reset))
   397  }
   398  
   399  // Unload mocks base method.
   400  func (m *MockDock) Unload(arg0, arg1 string, arg2 interface{}) error {
   401  	m.ctrl.T.Helper()
   402  	ret := m.ctrl.Call(m, "Unload", arg0, arg1, arg2)
   403  	ret0, _ := ret[0].(error)
   404  	return ret0
   405  }
   406  
   407  // Unload indicates an expected call of Unload.
   408  func (mr *MockDockMockRecorder) Unload(arg0, arg1, arg2 interface{}) *gomock.Call {
   409  	mr.mock.ctrl.T.Helper()
   410  	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Unload", reflect.TypeOf((*MockDock)(nil).Unload), arg0, arg1, arg2)
   411  }