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

package mocks

import (
	"github.com/aerospike/backup-go/models"
	mock "github.com/stretchr/testify/mock"
)

// NewMockProcessor creates a new instance of MockProcessor. 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 NewMockProcessor[T models.TokenConstraint](t interface {
	mock.TestingT
	Cleanup(func())
}) *MockProcessor[T] {
	mock := &MockProcessor[T]{}
	mock.Mock.Test(t)

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

	return mock
}

// MockProcessor is an autogenerated mock type for the Processor type
type MockProcessor[T models.TokenConstraint] struct {
	mock.Mock
}

type MockProcessor_Expecter[T models.TokenConstraint] struct {
	mock *mock.Mock
}

func (_m *MockProcessor[T]) EXPECT() *MockProcessor_Expecter[T] {
	return &MockProcessor_Expecter[T]{mock: &_m.Mock}
}

// Process provides a mock function for the type MockProcessor
func (_mock *MockProcessor[T]) Process(v T) (T, error) {
	ret := _mock.Called(v)

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

	var r0 T
	var r1 error
	if returnFunc, ok := ret.Get(0).(func(T) (T, error)); ok {
		return returnFunc(v)
	}
	if returnFunc, ok := ret.Get(0).(func(T) T); ok {
		r0 = returnFunc(v)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(T)
		}
	}
	if returnFunc, ok := ret.Get(1).(func(T) error); ok {
		r1 = returnFunc(v)
	} else {
		r1 = ret.Error(1)
	}
	return r0, r1
}

// MockProcessor_Process_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Process'
type MockProcessor_Process_Call[T models.TokenConstraint] struct {
	*mock.Call
}

// Process is a helper method to define mock.On call
//   - v
func (_e *MockProcessor_Expecter[T]) Process(v interface{}) *MockProcessor_Process_Call[T] {
	return &MockProcessor_Process_Call[T]{Call: _e.mock.On("Process", v)}
}

func (_c *MockProcessor_Process_Call[T]) Run(run func(v T)) *MockProcessor_Process_Call[T] {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(T))
	})
	return _c
}

func (_c *MockProcessor_Process_Call[T]) Return(v1 T, err error) *MockProcessor_Process_Call[T] {
	_c.Call.Return(v1, err)
	return _c
}

func (_c *MockProcessor_Process_Call[T]) RunAndReturn(run func(v T) (T, error)) *MockProcessor_Process_Call[T] {
	_c.Call.Return(run)
	return _c
}
