// Code generated by mockery; DO NOT EDIT.
// github.com/vektra/mockery
// template: testify

package mocks

import (
	"context"

	mock "github.com/stretchr/testify/mock"
)

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

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

	return mock
}

// MockSingleTaskPoller is an autogenerated mock type for the SingleTaskPoller type
type MockSingleTaskPoller struct {
	mock.Mock
}

type MockSingleTaskPoller_Expecter struct {
	mock *mock.Mock
}

func (_m *MockSingleTaskPoller) EXPECT() *MockSingleTaskPoller_Expecter {
	return &MockSingleTaskPoller_Expecter{mock: &_m.Mock}
}

// Poll provides a mock function for the type MockSingleTaskPoller
func (_mock *MockSingleTaskPoller) Poll() error {
	ret := _mock.Called()

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

	var r0 error
	if returnFunc, ok := ret.Get(0).(func() error); ok {
		r0 = returnFunc()
	} else {
		r0 = ret.Error(0)
	}
	return r0
}

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

// Poll is a helper method to define mock.On call
func (_e *MockSingleTaskPoller_Expecter) Poll() *MockSingleTaskPoller_Poll_Call {
	return &MockSingleTaskPoller_Poll_Call{Call: _e.mock.On("Poll")}
}

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

func (_c *MockSingleTaskPoller_Poll_Call) Return(err error) *MockSingleTaskPoller_Poll_Call {
	_c.Call.Return(err)
	return _c
}

func (_c *MockSingleTaskPoller_Poll_Call) RunAndReturn(run func() error) *MockSingleTaskPoller_Poll_Call {
	_c.Call.Return(run)
	return _c
}

// Shutdown provides a mock function for the type MockSingleTaskPoller
func (_mock *MockSingleTaskPoller) Shutdown(ctx context.Context) error {
	ret := _mock.Called(ctx)

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

	var r0 error
	if returnFunc, ok := ret.Get(0).(func(context.Context) error); ok {
		r0 = returnFunc(ctx)
	} else {
		r0 = ret.Error(0)
	}
	return r0
}

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

// Shutdown is a helper method to define mock.On call
//   - ctx context.Context
func (_e *MockSingleTaskPoller_Expecter) Shutdown(ctx interface{}) *MockSingleTaskPoller_Shutdown_Call {
	return &MockSingleTaskPoller_Shutdown_Call{Call: _e.mock.On("Shutdown", ctx)}
}

func (_c *MockSingleTaskPoller_Shutdown_Call) Run(run func(ctx context.Context)) *MockSingleTaskPoller_Shutdown_Call {
	_c.Call.Run(func(args mock.Arguments) {
		var arg0 context.Context
		if args[0] != nil {
			arg0 = args[0].(context.Context)
		}
		run(
			arg0,
		)
	})
	return _c
}

func (_c *MockSingleTaskPoller_Shutdown_Call) Return(err error) *MockSingleTaskPoller_Shutdown_Call {
	_c.Call.Return(err)
	return _c
}

func (_c *MockSingleTaskPoller_Shutdown_Call) RunAndReturn(run func(ctx context.Context) error) *MockSingleTaskPoller_Shutdown_Call {
	_c.Call.Return(run)
	return _c
}
