helpers/retry/mock_RunFunc.go (53 lines of code) (raw):

// Code generated by mockery v2.53.3. DO NOT EDIT. package retry import mock "github.com/stretchr/testify/mock" // MockRunFunc is an autogenerated mock type for the RunFunc type type MockRunFunc struct { mock.Mock } type MockRunFunc_Expecter struct { mock *mock.Mock } func (_m *MockRunFunc) EXPECT() *MockRunFunc_Expecter { return &MockRunFunc_Expecter{mock: &_m.Mock} } // Execute provides a mock function with no fields func (_m *MockRunFunc) Execute() error { ret := _m.Called() if len(ret) == 0 { panic("no return value specified for Execute") } var r0 error if rf, ok := ret.Get(0).(func() error); ok { r0 = rf() } else { r0 = ret.Error(0) } return r0 } // MockRunFunc_Execute_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Execute' type MockRunFunc_Execute_Call struct { *mock.Call } // Execute is a helper method to define mock.On call func (_e *MockRunFunc_Expecter) Execute() *MockRunFunc_Execute_Call { return &MockRunFunc_Execute_Call{Call: _e.mock.On("Execute")} } func (_c *MockRunFunc_Execute_Call) Run(run func()) *MockRunFunc_Execute_Call { _c.Call.Run(func(args mock.Arguments) { run() }) return _c } func (_c *MockRunFunc_Execute_Call) Return(_a0 error) *MockRunFunc_Execute_Call { _c.Call.Return(_a0) return _c } func (_c *MockRunFunc_Execute_Call) RunAndReturn(run func() error) *MockRunFunc_Execute_Call { _c.Call.Return(run) return _c } // NewMockRunFunc creates a new instance of MockRunFunc. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. // The first argument is typically a *testing.T value. func NewMockRunFunc(t interface { mock.TestingT Cleanup(func()) }) *MockRunFunc { mock := &MockRunFunc{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) }) return mock }