executors/docker/internal/exec/mock_dialerFactory.go (59 lines of code) (raw):

// Code generated by mockery v2.53.3. DO NOT EDIT. package exec import ( context "context" io "io" mock "github.com/stretchr/testify/mock" ) // mockDialerFactory is an autogenerated mock type for the dialerFactory type type mockDialerFactory struct { mock.Mock } type mockDialerFactory_Expecter struct { mock *mock.Mock } func (_m *mockDialerFactory) EXPECT() *mockDialerFactory_Expecter { return &mockDialerFactory_Expecter{mock: &_m.Mock} } // Execute provides a mock function with given fields: _a0, _a1 func (_m *mockDialerFactory) Execute(_a0 io.ReadCloser, _a1 io.Writer) func(context.Context) error { ret := _m.Called(_a0, _a1) if len(ret) == 0 { panic("no return value specified for Execute") } var r0 func(context.Context) error if rf, ok := ret.Get(0).(func(io.ReadCloser, io.Writer) func(context.Context) error); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(func(context.Context) error) } } return r0 } // mockDialerFactory_Execute_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Execute' type mockDialerFactory_Execute_Call struct { *mock.Call } // Execute is a helper method to define mock.On call // - _a0 io.ReadCloser // - _a1 io.Writer func (_e *mockDialerFactory_Expecter) Execute(_a0 interface{}, _a1 interface{}) *mockDialerFactory_Execute_Call { return &mockDialerFactory_Execute_Call{Call: _e.mock.On("Execute", _a0, _a1)} } func (_c *mockDialerFactory_Execute_Call) Run(run func(_a0 io.ReadCloser, _a1 io.Writer)) *mockDialerFactory_Execute_Call { _c.Call.Run(func(args mock.Arguments) { run(args[0].(io.ReadCloser), args[1].(io.Writer)) }) return _c } func (_c *mockDialerFactory_Execute_Call) Return(_a0 func(context.Context) error) *mockDialerFactory_Execute_Call { _c.Call.Return(_a0) return _c } func (_c *mockDialerFactory_Execute_Call) RunAndReturn(run func(io.ReadCloser, io.Writer) func(context.Context) error) *mockDialerFactory_Execute_Call { _c.Call.Return(run) return _c } // newMockDialerFactory creates a new instance of mockDialerFactory. 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 newMockDialerFactory(t interface { mock.TestingT Cleanup(func()) }) *mockDialerFactory { mock := &mockDialerFactory{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) }) return mock }