// Code generated by mockery v2.53.3. DO NOT EDIT.

package shellstest

import (
	mock "github.com/stretchr/testify/mock"
	shells "gitlab.com/gitlab-org/gitlab-runner/shells"
)

// mockShellWriterFactory is an autogenerated mock type for the shellWriterFactory type
type mockShellWriterFactory struct {
	mock.Mock
}

type mockShellWriterFactory_Expecter struct {
	mock *mock.Mock
}

func (_m *mockShellWriterFactory) EXPECT() *mockShellWriterFactory_Expecter {
	return &mockShellWriterFactory_Expecter{mock: &_m.Mock}
}

// Execute provides a mock function with no fields
func (_m *mockShellWriterFactory) Execute() shells.ShellWriter {
	ret := _m.Called()

	if len(ret) == 0 {
		panic("no return value specified for Execute")
	}

	var r0 shells.ShellWriter
	if rf, ok := ret.Get(0).(func() shells.ShellWriter); ok {
		r0 = rf()
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(shells.ShellWriter)
		}
	}

	return r0
}

// mockShellWriterFactory_Execute_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Execute'
type mockShellWriterFactory_Execute_Call struct {
	*mock.Call
}

// Execute is a helper method to define mock.On call
func (_e *mockShellWriterFactory_Expecter) Execute() *mockShellWriterFactory_Execute_Call {
	return &mockShellWriterFactory_Execute_Call{Call: _e.mock.On("Execute")}
}

func (_c *mockShellWriterFactory_Execute_Call) Run(run func()) *mockShellWriterFactory_Execute_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run()
	})
	return _c
}

func (_c *mockShellWriterFactory_Execute_Call) Return(_a0 shells.ShellWriter) *mockShellWriterFactory_Execute_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *mockShellWriterFactory_Execute_Call) RunAndReturn(run func() shells.ShellWriter) *mockShellWriterFactory_Execute_Call {
	_c.Call.Return(run)
	return _c
}

// newMockShellWriterFactory creates a new instance of mockShellWriterFactory. 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 newMockShellWriterFactory(t interface {
	mock.TestingT
	Cleanup(func())
}) *mockShellWriterFactory {
	mock := &mockShellWriterFactory{}
	mock.Mock.Test(t)

	t.Cleanup(func() { mock.AssertExpectations(t) })

	return mock
}
