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

package mocks

import (
	backend "github.com/berachain/beacon-kit/node-api/backend"

	common "github.com/berachain/beacon-kit/primitives/common"

	math "github.com/berachain/beacon-kit/primitives/math"

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

	types "github.com/berachain/beacon-kit/da/types"
)

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

type Backend_Expecter struct {
	mock *mock.Mock
}

func (_m *Backend) EXPECT() *Backend_Expecter {
	return &Backend_Expecter{mock: &_m.Mock}
}

// GetBlobSidecarsAtSlot provides a mock function with given fields: slot
func (_m *Backend) GetBlobSidecarsAtSlot(slot math.Slot) (types.BlobSidecars, error) {
	ret := _m.Called(slot)

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

	var r0 types.BlobSidecars
	var r1 error
	if rf, ok := ret.Get(0).(func(math.Slot) (types.BlobSidecars, error)); ok {
		return rf(slot)
	}
	if rf, ok := ret.Get(0).(func(math.Slot) types.BlobSidecars); ok {
		r0 = rf(slot)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(types.BlobSidecars)
		}
	}

	if rf, ok := ret.Get(1).(func(math.Slot) error); ok {
		r1 = rf(slot)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// GetBlobSidecarsAtSlot is a helper method to define mock.On call
//   - slot math.Slot
func (_e *Backend_Expecter) GetBlobSidecarsAtSlot(slot interface{}) *Backend_GetBlobSidecarsAtSlot_Call {
	return &Backend_GetBlobSidecarsAtSlot_Call{Call: _e.mock.On("GetBlobSidecarsAtSlot", slot)}
}

func (_c *Backend_GetBlobSidecarsAtSlot_Call) Run(run func(slot math.Slot)) *Backend_GetBlobSidecarsAtSlot_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(math.Slot))
	})
	return _c
}

func (_c *Backend_GetBlobSidecarsAtSlot_Call) Return(_a0 types.BlobSidecars, _a1 error) *Backend_GetBlobSidecarsAtSlot_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *Backend_GetBlobSidecarsAtSlot_Call) RunAndReturn(run func(math.Slot) (types.BlobSidecars, error)) *Backend_GetBlobSidecarsAtSlot_Call {
	_c.Call.Return(run)
	return _c
}

// GetSlotByBlockRoot provides a mock function with given fields: root
func (_m *Backend) GetSlotByBlockRoot(root common.Root) (math.Slot, error) {
	ret := _m.Called(root)

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

	var r0 math.Slot
	var r1 error
	if rf, ok := ret.Get(0).(func(common.Root) (math.Slot, error)); ok {
		return rf(root)
	}
	if rf, ok := ret.Get(0).(func(common.Root) math.Slot); ok {
		r0 = rf(root)
	} else {
		r0 = ret.Get(0).(math.Slot)
	}

	if rf, ok := ret.Get(1).(func(common.Root) error); ok {
		r1 = rf(root)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// GetSlotByBlockRoot is a helper method to define mock.On call
//   - root common.Root
func (_e *Backend_Expecter) GetSlotByBlockRoot(root interface{}) *Backend_GetSlotByBlockRoot_Call {
	return &Backend_GetSlotByBlockRoot_Call{Call: _e.mock.On("GetSlotByBlockRoot", root)}
}

func (_c *Backend_GetSlotByBlockRoot_Call) Run(run func(root common.Root)) *Backend_GetSlotByBlockRoot_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(common.Root))
	})
	return _c
}

func (_c *Backend_GetSlotByBlockRoot_Call) Return(_a0 math.Slot, _a1 error) *Backend_GetSlotByBlockRoot_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *Backend_GetSlotByBlockRoot_Call) RunAndReturn(run func(common.Root) (math.Slot, error)) *Backend_GetSlotByBlockRoot_Call {
	_c.Call.Return(run)
	return _c
}

// GetSlotByStateRoot provides a mock function with given fields: root
func (_m *Backend) GetSlotByStateRoot(root common.Root) (math.Slot, error) {
	ret := _m.Called(root)

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

	var r0 math.Slot
	var r1 error
	if rf, ok := ret.Get(0).(func(common.Root) (math.Slot, error)); ok {
		return rf(root)
	}
	if rf, ok := ret.Get(0).(func(common.Root) math.Slot); ok {
		r0 = rf(root)
	} else {
		r0 = ret.Get(0).(math.Slot)
	}

	if rf, ok := ret.Get(1).(func(common.Root) error); ok {
		r1 = rf(root)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// GetSlotByStateRoot is a helper method to define mock.On call
//   - root common.Root
func (_e *Backend_Expecter) GetSlotByStateRoot(root interface{}) *Backend_GetSlotByStateRoot_Call {
	return &Backend_GetSlotByStateRoot_Call{Call: _e.mock.On("GetSlotByStateRoot", root)}
}

func (_c *Backend_GetSlotByStateRoot_Call) Run(run func(root common.Root)) *Backend_GetSlotByStateRoot_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(common.Root))
	})
	return _c
}

func (_c *Backend_GetSlotByStateRoot_Call) Return(_a0 math.Slot, _a1 error) *Backend_GetSlotByStateRoot_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *Backend_GetSlotByStateRoot_Call) RunAndReturn(run func(common.Root) (math.Slot, error)) *Backend_GetSlotByStateRoot_Call {
	_c.Call.Return(run)
	return _c
}

// GetSyncData provides a mock function with no fields
func (_m *Backend) GetSyncData() (int64, int64) {
	ret := _m.Called()

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

	var r0 int64
	var r1 int64
	if rf, ok := ret.Get(0).(func() (int64, int64)); ok {
		return rf()
	}
	if rf, ok := ret.Get(0).(func() int64); ok {
		r0 = rf()
	} else {
		r0 = ret.Get(0).(int64)
	}

	if rf, ok := ret.Get(1).(func() int64); ok {
		r1 = rf()
	} else {
		r1 = ret.Get(1).(int64)
	}

	return r0, r1
}

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

// GetSyncData is a helper method to define mock.On call
func (_e *Backend_Expecter) GetSyncData() *Backend_GetSyncData_Call {
	return &Backend_GetSyncData_Call{Call: _e.mock.On("GetSyncData")}
}

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

func (_c *Backend_GetSyncData_Call) Return(_a0 int64, _a1 int64) *Backend_GetSyncData_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *Backend_GetSyncData_Call) RunAndReturn(run func() (int64, int64)) *Backend_GetSyncData_Call {
	_c.Call.Return(run)
	return _c
}

// StateAndSlotFromHeight provides a mock function with given fields: height
func (_m *Backend) StateAndSlotFromHeight(height int64) (backend.ReadOnlyBeaconState, math.Slot, error) {
	ret := _m.Called(height)

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

	var r0 backend.ReadOnlyBeaconState
	var r1 math.Slot
	var r2 error
	if rf, ok := ret.Get(0).(func(int64) (backend.ReadOnlyBeaconState, math.Slot, error)); ok {
		return rf(height)
	}
	if rf, ok := ret.Get(0).(func(int64) backend.ReadOnlyBeaconState); ok {
		r0 = rf(height)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(backend.ReadOnlyBeaconState)
		}
	}

	if rf, ok := ret.Get(1).(func(int64) math.Slot); ok {
		r1 = rf(height)
	} else {
		r1 = ret.Get(1).(math.Slot)
	}

	if rf, ok := ret.Get(2).(func(int64) error); ok {
		r2 = rf(height)
	} else {
		r2 = ret.Error(2)
	}

	return r0, r1, r2
}

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

// StateAndSlotFromHeight is a helper method to define mock.On call
//   - height int64
func (_e *Backend_Expecter) StateAndSlotFromHeight(height interface{}) *Backend_StateAndSlotFromHeight_Call {
	return &Backend_StateAndSlotFromHeight_Call{Call: _e.mock.On("StateAndSlotFromHeight", height)}
}

func (_c *Backend_StateAndSlotFromHeight_Call) Run(run func(height int64)) *Backend_StateAndSlotFromHeight_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(int64))
	})
	return _c
}

func (_c *Backend_StateAndSlotFromHeight_Call) Return(_a0 backend.ReadOnlyBeaconState, _a1 math.Slot, _a2 error) *Backend_StateAndSlotFromHeight_Call {
	_c.Call.Return(_a0, _a1, _a2)
	return _c
}

func (_c *Backend_StateAndSlotFromHeight_Call) RunAndReturn(run func(int64) (backend.ReadOnlyBeaconState, math.Slot, error)) *Backend_StateAndSlotFromHeight_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
