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

package mocks

import (
	api "github.com/hyperledger-labs/SmartBFT/pkg/api"
	bccsp "github.com/hyperledger/fabric-lib-go/bccsp"

	cluster "github.com/hyperledger/fabric/orderer/common/cluster"

	common "github.com/hyperledger/fabric-protos-go-apiv2/common"

	consensus "github.com/hyperledger/fabric/orderer/consensus"

	flogging "github.com/hyperledger/fabric-lib-go/common/flogging"

	localconfig "github.com/hyperledger/fabric/orderer/common/localconfig"

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

	smartbft "github.com/hyperledger/fabric/orderer/consensus/smartbft"

	types "github.com/hyperledger-labs/SmartBFT/pkg/types"
)

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

type SynchronizerFactory_Expecter struct {
	mock *mock.Mock
}

func (_m *SynchronizerFactory) EXPECT() *SynchronizerFactory_Expecter {
	return &SynchronizerFactory_Expecter{mock: &_m.Mock}
}

// CreateSynchronizer provides a mock function with given fields: logger, localConfigCluster, rtc, blockToDecision, pruneCommittedRequests, updateRuntimeConfig, support, _a7, clusterDialer
func (_m *SynchronizerFactory) CreateSynchronizer(logger *flogging.FabricLogger, localConfigCluster localconfig.Cluster, rtc smartbft.RuntimeConfig, blockToDecision func(*common.Block) *types.Decision, pruneCommittedRequests func(*common.Block), updateRuntimeConfig func(*common.Block) types.Reconfig, support consensus.ConsenterSupport, _a7 bccsp.BCCSP, clusterDialer *cluster.PredicateDialer) api.Synchronizer {
	ret := _m.Called(logger, localConfigCluster, rtc, blockToDecision, pruneCommittedRequests, updateRuntimeConfig, support, _a7, clusterDialer)

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

	var r0 api.Synchronizer
	if rf, ok := ret.Get(0).(func(*flogging.FabricLogger, localconfig.Cluster, smartbft.RuntimeConfig, func(*common.Block) *types.Decision, func(*common.Block), func(*common.Block) types.Reconfig, consensus.ConsenterSupport, bccsp.BCCSP, *cluster.PredicateDialer) api.Synchronizer); ok {
		r0 = rf(logger, localConfigCluster, rtc, blockToDecision, pruneCommittedRequests, updateRuntimeConfig, support, _a7, clusterDialer)
	} else {
		if ret.Get(0) != nil {
			r0 = ret.Get(0).(api.Synchronizer)
		}
	}

	return r0
}

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

// CreateSynchronizer is a helper method to define mock.On call
//   - logger *flogging.FabricLogger
//   - localConfigCluster localconfig.Cluster
//   - rtc smartbft.RuntimeConfig
//   - blockToDecision func(*common.Block) *types.Decision
//   - pruneCommittedRequests func(*common.Block)
//   - updateRuntimeConfig func(*common.Block) types.Reconfig
//   - support consensus.ConsenterSupport
//   - _a7 bccsp.BCCSP
//   - clusterDialer *cluster.PredicateDialer
func (_e *SynchronizerFactory_Expecter) CreateSynchronizer(logger interface{}, localConfigCluster interface{}, rtc interface{}, blockToDecision interface{}, pruneCommittedRequests interface{}, updateRuntimeConfig interface{}, support interface{}, _a7 interface{}, clusterDialer interface{}) *SynchronizerFactory_CreateSynchronizer_Call {
	return &SynchronizerFactory_CreateSynchronizer_Call{Call: _e.mock.On("CreateSynchronizer", logger, localConfigCluster, rtc, blockToDecision, pruneCommittedRequests, updateRuntimeConfig, support, _a7, clusterDialer)}
}

func (_c *SynchronizerFactory_CreateSynchronizer_Call) Run(run func(logger *flogging.FabricLogger, localConfigCluster localconfig.Cluster, rtc smartbft.RuntimeConfig, blockToDecision func(*common.Block) *types.Decision, pruneCommittedRequests func(*common.Block), updateRuntimeConfig func(*common.Block) types.Reconfig, support consensus.ConsenterSupport, _a7 bccsp.BCCSP, clusterDialer *cluster.PredicateDialer)) *SynchronizerFactory_CreateSynchronizer_Call {
	_c.Call.Run(func(args mock.Arguments) {
		run(args[0].(*flogging.FabricLogger), args[1].(localconfig.Cluster), args[2].(smartbft.RuntimeConfig), args[3].(func(*common.Block) *types.Decision), args[4].(func(*common.Block)), args[5].(func(*common.Block) types.Reconfig), args[6].(consensus.ConsenterSupport), args[7].(bccsp.BCCSP), args[8].(*cluster.PredicateDialer))
	})
	return _c
}

func (_c *SynchronizerFactory_CreateSynchronizer_Call) Return(_a0 api.Synchronizer) *SynchronizerFactory_CreateSynchronizer_Call {
	_c.Call.Return(_a0)
	return _c
}

func (_c *SynchronizerFactory_CreateSynchronizer_Call) RunAndReturn(run func(*flogging.FabricLogger, localconfig.Cluster, smartbft.RuntimeConfig, func(*common.Block) *types.Decision, func(*common.Block), func(*common.Block) types.Reconfig, consensus.ConsenterSupport, bccsp.BCCSP, *cluster.PredicateDialer) api.Synchronizer) *SynchronizerFactory_CreateSynchronizer_Call {
	_c.Call.Return(run)
	return _c
}

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

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

	return mock
}
