github.com/ari-anchor/sei-tendermint@v0.0.0-20230519144642-dc826b7b56bb/abci/client/mocks/client.go (about)

     1  // Code generated by mockery. DO NOT EDIT.
     2  
     3  package mocks
     4  
     5  import (
     6  	context "context"
     7  
     8  	mock "github.com/stretchr/testify/mock"
     9  	types "github.com/ari-anchor/sei-tendermint/abci/types"
    10  )
    11  
    12  // Client is an autogenerated mock type for the Client type
    13  type Client struct {
    14  	mock.Mock
    15  }
    16  
    17  // ApplySnapshotChunk provides a mock function with given fields: _a0, _a1
    18  func (_m *Client) ApplySnapshotChunk(_a0 context.Context, _a1 *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error) {
    19  	ret := _m.Called(_a0, _a1)
    20  
    21  	var r0 *types.ResponseApplySnapshotChunk
    22  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) *types.ResponseApplySnapshotChunk); ok {
    23  		r0 = rf(_a0, _a1)
    24  	} else {
    25  		if ret.Get(0) != nil {
    26  			r0 = ret.Get(0).(*types.ResponseApplySnapshotChunk)
    27  		}
    28  	}
    29  
    30  	var r1 error
    31  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestApplySnapshotChunk) error); ok {
    32  		r1 = rf(_a0, _a1)
    33  	} else {
    34  		r1 = ret.Error(1)
    35  	}
    36  
    37  	return r0, r1
    38  }
    39  
    40  // CheckTx provides a mock function with given fields: _a0, _a1
    41  func (_m *Client) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) (*types.ResponseCheckTx, error) {
    42  	ret := _m.Called(_a0, _a1)
    43  
    44  	var r0 *types.ResponseCheckTx
    45  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *types.ResponseCheckTx); ok {
    46  		r0 = rf(_a0, _a1)
    47  	} else {
    48  		if ret.Get(0) != nil {
    49  			r0 = ret.Get(0).(*types.ResponseCheckTx)
    50  		}
    51  	}
    52  
    53  	var r1 error
    54  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok {
    55  		r1 = rf(_a0, _a1)
    56  	} else {
    57  		r1 = ret.Error(1)
    58  	}
    59  
    60  	return r0, r1
    61  }
    62  
    63  // Commit provides a mock function with given fields: _a0
    64  func (_m *Client) Commit(_a0 context.Context) (*types.ResponseCommit, error) {
    65  	ret := _m.Called(_a0)
    66  
    67  	var r0 *types.ResponseCommit
    68  	if rf, ok := ret.Get(0).(func(context.Context) *types.ResponseCommit); ok {
    69  		r0 = rf(_a0)
    70  	} else {
    71  		if ret.Get(0) != nil {
    72  			r0 = ret.Get(0).(*types.ResponseCommit)
    73  		}
    74  	}
    75  
    76  	var r1 error
    77  	if rf, ok := ret.Get(1).(func(context.Context) error); ok {
    78  		r1 = rf(_a0)
    79  	} else {
    80  		r1 = ret.Error(1)
    81  	}
    82  
    83  	return r0, r1
    84  }
    85  
    86  // Echo provides a mock function with given fields: _a0, _a1
    87  func (_m *Client) Echo(_a0 context.Context, _a1 string) (*types.ResponseEcho, error) {
    88  	ret := _m.Called(_a0, _a1)
    89  
    90  	var r0 *types.ResponseEcho
    91  	if rf, ok := ret.Get(0).(func(context.Context, string) *types.ResponseEcho); ok {
    92  		r0 = rf(_a0, _a1)
    93  	} else {
    94  		if ret.Get(0) != nil {
    95  			r0 = ret.Get(0).(*types.ResponseEcho)
    96  		}
    97  	}
    98  
    99  	var r1 error
   100  	if rf, ok := ret.Get(1).(func(context.Context, string) error); ok {
   101  		r1 = rf(_a0, _a1)
   102  	} else {
   103  		r1 = ret.Error(1)
   104  	}
   105  
   106  	return r0, r1
   107  }
   108  
   109  // Error provides a mock function with given fields:
   110  func (_m *Client) Error() error {
   111  	ret := _m.Called()
   112  
   113  	var r0 error
   114  	if rf, ok := ret.Get(0).(func() error); ok {
   115  		r0 = rf()
   116  	} else {
   117  		r0 = ret.Error(0)
   118  	}
   119  
   120  	return r0
   121  }
   122  
   123  // ExtendVote provides a mock function with given fields: _a0, _a1
   124  func (_m *Client) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendVote) (*types.ResponseExtendVote, error) {
   125  	ret := _m.Called(_a0, _a1)
   126  
   127  	var r0 *types.ResponseExtendVote
   128  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) *types.ResponseExtendVote); ok {
   129  		r0 = rf(_a0, _a1)
   130  	} else {
   131  		if ret.Get(0) != nil {
   132  			r0 = ret.Get(0).(*types.ResponseExtendVote)
   133  		}
   134  	}
   135  
   136  	var r1 error
   137  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestExtendVote) error); ok {
   138  		r1 = rf(_a0, _a1)
   139  	} else {
   140  		r1 = ret.Error(1)
   141  	}
   142  
   143  	return r0, r1
   144  }
   145  
   146  // FinalizeBlock provides a mock function with given fields: _a0, _a1
   147  func (_m *Client) FinalizeBlock(_a0 context.Context, _a1 *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error) {
   148  	ret := _m.Called(_a0, _a1)
   149  
   150  	var r0 *types.ResponseFinalizeBlock
   151  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) *types.ResponseFinalizeBlock); ok {
   152  		r0 = rf(_a0, _a1)
   153  	} else {
   154  		if ret.Get(0) != nil {
   155  			r0 = ret.Get(0).(*types.ResponseFinalizeBlock)
   156  		}
   157  	}
   158  
   159  	var r1 error
   160  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestFinalizeBlock) error); ok {
   161  		r1 = rf(_a0, _a1)
   162  	} else {
   163  		r1 = ret.Error(1)
   164  	}
   165  
   166  	return r0, r1
   167  }
   168  
   169  // Flush provides a mock function with given fields: _a0
   170  func (_m *Client) Flush(_a0 context.Context) error {
   171  	ret := _m.Called(_a0)
   172  
   173  	var r0 error
   174  	if rf, ok := ret.Get(0).(func(context.Context) error); ok {
   175  		r0 = rf(_a0)
   176  	} else {
   177  		r0 = ret.Error(0)
   178  	}
   179  
   180  	return r0
   181  }
   182  
   183  // Info provides a mock function with given fields: _a0, _a1
   184  func (_m *Client) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types.ResponseInfo, error) {
   185  	ret := _m.Called(_a0, _a1)
   186  
   187  	var r0 *types.ResponseInfo
   188  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) *types.ResponseInfo); ok {
   189  		r0 = rf(_a0, _a1)
   190  	} else {
   191  		if ret.Get(0) != nil {
   192  			r0 = ret.Get(0).(*types.ResponseInfo)
   193  		}
   194  	}
   195  
   196  	var r1 error
   197  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInfo) error); ok {
   198  		r1 = rf(_a0, _a1)
   199  	} else {
   200  		r1 = ret.Error(1)
   201  	}
   202  
   203  	return r0, r1
   204  }
   205  
   206  // InitChain provides a mock function with given fields: _a0, _a1
   207  func (_m *Client) InitChain(_a0 context.Context, _a1 *types.RequestInitChain) (*types.ResponseInitChain, error) {
   208  	ret := _m.Called(_a0, _a1)
   209  
   210  	var r0 *types.ResponseInitChain
   211  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) *types.ResponseInitChain); ok {
   212  		r0 = rf(_a0, _a1)
   213  	} else {
   214  		if ret.Get(0) != nil {
   215  			r0 = ret.Get(0).(*types.ResponseInitChain)
   216  		}
   217  	}
   218  
   219  	var r1 error
   220  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInitChain) error); ok {
   221  		r1 = rf(_a0, _a1)
   222  	} else {
   223  		r1 = ret.Error(1)
   224  	}
   225  
   226  	return r0, r1
   227  }
   228  
   229  // IsRunning provides a mock function with given fields:
   230  func (_m *Client) IsRunning() bool {
   231  	ret := _m.Called()
   232  
   233  	var r0 bool
   234  	if rf, ok := ret.Get(0).(func() bool); ok {
   235  		r0 = rf()
   236  	} else {
   237  		r0 = ret.Get(0).(bool)
   238  	}
   239  
   240  	return r0
   241  }
   242  
   243  // ListSnapshots provides a mock function with given fields: _a0, _a1
   244  func (_m *Client) ListSnapshots(_a0 context.Context, _a1 *types.RequestListSnapshots) (*types.ResponseListSnapshots, error) {
   245  	ret := _m.Called(_a0, _a1)
   246  
   247  	var r0 *types.ResponseListSnapshots
   248  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) *types.ResponseListSnapshots); ok {
   249  		r0 = rf(_a0, _a1)
   250  	} else {
   251  		if ret.Get(0) != nil {
   252  			r0 = ret.Get(0).(*types.ResponseListSnapshots)
   253  		}
   254  	}
   255  
   256  	var r1 error
   257  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestListSnapshots) error); ok {
   258  		r1 = rf(_a0, _a1)
   259  	} else {
   260  		r1 = ret.Error(1)
   261  	}
   262  
   263  	return r0, r1
   264  }
   265  
   266  // LoadLatest provides a mock function with given fields: _a0, _a1
   267  func (_m *Client) LoadLatest(_a0 context.Context, _a1 *types.RequestLoadLatest) (*types.ResponseLoadLatest, error) {
   268  	ret := _m.Called(_a0, _a1)
   269  
   270  	var r0 *types.ResponseLoadLatest
   271  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadLatest) *types.ResponseLoadLatest); ok {
   272  		r0 = rf(_a0, _a1)
   273  	} else {
   274  		if ret.Get(0) != nil {
   275  			r0 = ret.Get(0).(*types.ResponseLoadLatest)
   276  		}
   277  	}
   278  
   279  	var r1 error
   280  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestLoadLatest) error); ok {
   281  		r1 = rf(_a0, _a1)
   282  	} else {
   283  		r1 = ret.Error(1)
   284  	}
   285  
   286  	return r0, r1
   287  }
   288  
   289  // LoadSnapshotChunk provides a mock function with given fields: _a0, _a1
   290  func (_m *Client) LoadSnapshotChunk(_a0 context.Context, _a1 *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error) {
   291  	ret := _m.Called(_a0, _a1)
   292  
   293  	var r0 *types.ResponseLoadSnapshotChunk
   294  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) *types.ResponseLoadSnapshotChunk); ok {
   295  		r0 = rf(_a0, _a1)
   296  	} else {
   297  		if ret.Get(0) != nil {
   298  			r0 = ret.Get(0).(*types.ResponseLoadSnapshotChunk)
   299  		}
   300  	}
   301  
   302  	var r1 error
   303  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestLoadSnapshotChunk) error); ok {
   304  		r1 = rf(_a0, _a1)
   305  	} else {
   306  		r1 = ret.Error(1)
   307  	}
   308  
   309  	return r0, r1
   310  }
   311  
   312  // OfferSnapshot provides a mock function with given fields: _a0, _a1
   313  func (_m *Client) OfferSnapshot(_a0 context.Context, _a1 *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error) {
   314  	ret := _m.Called(_a0, _a1)
   315  
   316  	var r0 *types.ResponseOfferSnapshot
   317  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) *types.ResponseOfferSnapshot); ok {
   318  		r0 = rf(_a0, _a1)
   319  	} else {
   320  		if ret.Get(0) != nil {
   321  			r0 = ret.Get(0).(*types.ResponseOfferSnapshot)
   322  		}
   323  	}
   324  
   325  	var r1 error
   326  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestOfferSnapshot) error); ok {
   327  		r1 = rf(_a0, _a1)
   328  	} else {
   329  		r1 = ret.Error(1)
   330  	}
   331  
   332  	return r0, r1
   333  }
   334  
   335  // PrepareProposal provides a mock function with given fields: _a0, _a1
   336  func (_m *Client) PrepareProposal(_a0 context.Context, _a1 *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error) {
   337  	ret := _m.Called(_a0, _a1)
   338  
   339  	var r0 *types.ResponsePrepareProposal
   340  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) *types.ResponsePrepareProposal); ok {
   341  		r0 = rf(_a0, _a1)
   342  	} else {
   343  		if ret.Get(0) != nil {
   344  			r0 = ret.Get(0).(*types.ResponsePrepareProposal)
   345  		}
   346  	}
   347  
   348  	var r1 error
   349  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestPrepareProposal) error); ok {
   350  		r1 = rf(_a0, _a1)
   351  	} else {
   352  		r1 = ret.Error(1)
   353  	}
   354  
   355  	return r0, r1
   356  }
   357  
   358  // ProcessProposal provides a mock function with given fields: _a0, _a1
   359  func (_m *Client) ProcessProposal(_a0 context.Context, _a1 *types.RequestProcessProposal) (*types.ResponseProcessProposal, error) {
   360  	ret := _m.Called(_a0, _a1)
   361  
   362  	var r0 *types.ResponseProcessProposal
   363  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) *types.ResponseProcessProposal); ok {
   364  		r0 = rf(_a0, _a1)
   365  	} else {
   366  		if ret.Get(0) != nil {
   367  			r0 = ret.Get(0).(*types.ResponseProcessProposal)
   368  		}
   369  	}
   370  
   371  	var r1 error
   372  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestProcessProposal) error); ok {
   373  		r1 = rf(_a0, _a1)
   374  	} else {
   375  		r1 = ret.Error(1)
   376  	}
   377  
   378  	return r0, r1
   379  }
   380  
   381  // Query provides a mock function with given fields: _a0, _a1
   382  func (_m *Client) Query(_a0 context.Context, _a1 *types.RequestQuery) (*types.ResponseQuery, error) {
   383  	ret := _m.Called(_a0, _a1)
   384  
   385  	var r0 *types.ResponseQuery
   386  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) *types.ResponseQuery); ok {
   387  		r0 = rf(_a0, _a1)
   388  	} else {
   389  		if ret.Get(0) != nil {
   390  			r0 = ret.Get(0).(*types.ResponseQuery)
   391  		}
   392  	}
   393  
   394  	var r1 error
   395  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestQuery) error); ok {
   396  		r1 = rf(_a0, _a1)
   397  	} else {
   398  		r1 = ret.Error(1)
   399  	}
   400  
   401  	return r0, r1
   402  }
   403  
   404  // Start provides a mock function with given fields: _a0
   405  func (_m *Client) Start(_a0 context.Context) error {
   406  	ret := _m.Called(_a0)
   407  
   408  	var r0 error
   409  	if rf, ok := ret.Get(0).(func(context.Context) error); ok {
   410  		r0 = rf(_a0)
   411  	} else {
   412  		r0 = ret.Error(0)
   413  	}
   414  
   415  	return r0
   416  }
   417  
   418  // Stop provides a mock function with given fields:
   419  func (_m *Client) Stop() {
   420  	_m.Called()
   421  }
   422  
   423  // VerifyVoteExtension provides a mock function with given fields: _a0, _a1
   424  func (_m *Client) VerifyVoteExtension(_a0 context.Context, _a1 *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) {
   425  	ret := _m.Called(_a0, _a1)
   426  
   427  	var r0 *types.ResponseVerifyVoteExtension
   428  	if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) *types.ResponseVerifyVoteExtension); ok {
   429  		r0 = rf(_a0, _a1)
   430  	} else {
   431  		if ret.Get(0) != nil {
   432  			r0 = ret.Get(0).(*types.ResponseVerifyVoteExtension)
   433  		}
   434  	}
   435  
   436  	var r1 error
   437  	if rf, ok := ret.Get(1).(func(context.Context, *types.RequestVerifyVoteExtension) error); ok {
   438  		r1 = rf(_a0, _a1)
   439  	} else {
   440  		r1 = ret.Error(1)
   441  	}
   442  
   443  	return r0, r1
   444  }
   445  
   446  // Wait provides a mock function with given fields:
   447  func (_m *Client) Wait() {
   448  	_m.Called()
   449  }
   450  
   451  type NewClientT interface {
   452  	mock.TestingT
   453  	Cleanup(func())
   454  }
   455  
   456  // NewClient creates a new instance of Client. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
   457  func NewClient(t NewClientT) *Client {
   458  	mock := &Client{}
   459  	mock.Mock.Test(t)
   460  
   461  	t.Cleanup(func() { mock.AssertExpectations(t) })
   462  
   463  	return mock
   464  }