// Code generated by mockery. DO NOT EDIT.

package mocks

import (
	context "context"

	aggsendertypes "github.com/agglayer/aggkit/aggsender/types"

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

	types "github.com/agglayer/aggkit/agglayer/types"
)

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

type CertificateQuerier_Expecter struct {
	mock *mock.Mock
}

func (_m *CertificateQuerier) EXPECT() *CertificateQuerier_Expecter {
	return &CertificateQuerier_Expecter{mock: &_m.Mock}
}

// CalculateCertificateType provides a mock function with given fields: cert, certToBlock
func (_m *CertificateQuerier) CalculateCertificateType(cert *types.Certificate, certToBlock uint64) aggsendertypes.CertificateType {
	ret := _m.Called(cert, certToBlock)

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

	var r0 aggsendertypes.CertificateType
	if rf, ok := ret.Get(0).(func(*types.Certificate, uint64) aggsendertypes.CertificateType); ok {
		r0 = rf(cert, certToBlock)
	} else {
		r0 = ret.Get(0).(aggsendertypes.CertificateType)
	}

	return r0
}

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

// CalculateCertificateType is a helper method to define mock.On call
//   - cert *types.Certificate
//   - certToBlock uint64
func (_e *CertificateQuerier_Expecter) CalculateCertificateType(cert interface{}, certToBlock interface{}) *CertificateQuerier_CalculateCertificateType_Call {
	return &CertificateQuerier_CalculateCertificateType_Call{Call: _e.mock.On("CalculateCertificateType", cert, certToBlock)}
}

func (_c *CertificateQuerier_CalculateCertificateType_Call) Run(run func(cert *types.Certificate, certToBlock uint64)) *CertificateQuerier_CalculateCertificateType_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(*types.Certificate), args[1].(uint64))
	})
	return _c
}

func (_c *CertificateQuerier_CalculateCertificateType_Call) Return(_a0 aggsendertypes.CertificateType) *CertificateQuerier_CalculateCertificateType_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *CertificateQuerier_CalculateCertificateType_Call) RunAndReturn(run func(*types.Certificate, uint64) aggsendertypes.CertificateType) *CertificateQuerier_CalculateCertificateType_Call {
	_c.Call.Return(run)
	return _c
}

// CalculateCertificateTypeFromToBlock provides a mock function with given fields: certToBlock
func (_m *CertificateQuerier) CalculateCertificateTypeFromToBlock(certToBlock uint64) aggsendertypes.CertificateType {
	ret := _m.Called(certToBlock)

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

	var r0 aggsendertypes.CertificateType
	if rf, ok := ret.Get(0).(func(uint64) aggsendertypes.CertificateType); ok {
		r0 = rf(certToBlock)
	} else {
		r0 = ret.Get(0).(aggsendertypes.CertificateType)
	}

	return r0
}

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

// CalculateCertificateTypeFromToBlock is a helper method to define mock.On call
//   - certToBlock uint64
func (_e *CertificateQuerier_Expecter) CalculateCertificateTypeFromToBlock(certToBlock interface{}) *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call {
	return &CertificateQuerier_CalculateCertificateTypeFromToBlock_Call{Call: _e.mock.On("CalculateCertificateTypeFromToBlock", certToBlock)}
}

func (_c *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call) Run(run func(certToBlock uint64)) *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(uint64))
	})
	return _c
}

func (_c *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call) Return(_a0 aggsendertypes.CertificateType) *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call) RunAndReturn(run func(uint64) aggsendertypes.CertificateType) *CertificateQuerier_CalculateCertificateTypeFromToBlock_Call {
	_c.Call.Return(run)
	return _c
}

// GetLastSettledCertificateToBlock provides a mock function with given fields: ctx, cert
func (_m *CertificateQuerier) GetLastSettledCertificateToBlock(ctx context.Context, cert *types.CertificateHeader) (uint64, error) {
	ret := _m.Called(ctx, cert)

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

	var r0 uint64
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *types.CertificateHeader) (uint64, error)); ok {
		return rf(ctx, cert)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *types.CertificateHeader) uint64); ok {
		r0 = rf(ctx, cert)
	} else {
		r0 = ret.Get(0).(uint64)
	}

	if rf, ok := ret.Get(1).(func(context.Context, *types.CertificateHeader) error); ok {
		r1 = rf(ctx, cert)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// GetLastSettledCertificateToBlock is a helper method to define mock.On call
//   - ctx context.Context
//   - cert *types.CertificateHeader
func (_e *CertificateQuerier_Expecter) GetLastSettledCertificateToBlock(ctx interface{}, cert interface{}) *CertificateQuerier_GetLastSettledCertificateToBlock_Call {
	return &CertificateQuerier_GetLastSettledCertificateToBlock_Call{Call: _e.mock.On("GetLastSettledCertificateToBlock", ctx, cert)}
}

func (_c *CertificateQuerier_GetLastSettledCertificateToBlock_Call) Run(run func(ctx context.Context, cert *types.CertificateHeader)) *CertificateQuerier_GetLastSettledCertificateToBlock_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*types.CertificateHeader))
	})
	return _c
}

func (_c *CertificateQuerier_GetLastSettledCertificateToBlock_Call) Return(_a0 uint64, _a1 error) *CertificateQuerier_GetLastSettledCertificateToBlock_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *CertificateQuerier_GetLastSettledCertificateToBlock_Call) RunAndReturn(run func(context.Context, *types.CertificateHeader) (uint64, error)) *CertificateQuerier_GetLastSettledCertificateToBlock_Call {
	_c.Call.Return(run)
	return _c
}

// GetNewCertificateToBlock provides a mock function with given fields: ctx, cert
func (_m *CertificateQuerier) GetNewCertificateToBlock(ctx context.Context, cert *types.Certificate) (uint64, error) {
	ret := _m.Called(ctx, cert)

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

	var r0 uint64
	var r1 error
	if rf, ok := ret.Get(0).(func(context.Context, *types.Certificate) (uint64, error)); ok {
		return rf(ctx, cert)
	}
	if rf, ok := ret.Get(0).(func(context.Context, *types.Certificate) uint64); ok {
		r0 = rf(ctx, cert)
	} else {
		r0 = ret.Get(0).(uint64)
	}

	if rf, ok := ret.Get(1).(func(context.Context, *types.Certificate) error); ok {
		r1 = rf(ctx, cert)
	} else {
		r1 = ret.Error(1)
	}

	return r0, r1
}

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

// GetNewCertificateToBlock is a helper method to define mock.On call
//   - ctx context.Context
//   - cert *types.Certificate
func (_e *CertificateQuerier_Expecter) GetNewCertificateToBlock(ctx interface{}, cert interface{}) *CertificateQuerier_GetNewCertificateToBlock_Call {
	return &CertificateQuerier_GetNewCertificateToBlock_Call{Call: _e.mock.On("GetNewCertificateToBlock", ctx, cert)}
}

func (_c *CertificateQuerier_GetNewCertificateToBlock_Call) Run(run func(ctx context.Context, cert *types.Certificate)) *CertificateQuerier_GetNewCertificateToBlock_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(context.Context), args[1].(*types.Certificate))
	})
	return _c
}

func (_c *CertificateQuerier_GetNewCertificateToBlock_Call) Return(_a0 uint64, _a1 error) *CertificateQuerier_GetNewCertificateToBlock_Call {
	_c.Call.Return(_a0, _a1)
	return _c
}

func (_c *CertificateQuerier_GetNewCertificateToBlock_Call) RunAndReturn(run func(context.Context, *types.Certificate) (uint64, error)) *CertificateQuerier_GetNewCertificateToBlock_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
