// Code generated by MockGen. DO NOT EDIT.
// Source: election.go
//
// Generated by this command:
//
//	mockgen -package election -source election.go -destination=election_mock.go Factory,Elector
//

// Package election is a generated GoMock package.
package election

import (
	context "context"
	reflect "reflect"

	gomock "go.uber.org/mock/gomock"

	config "github.com/uber/cadence/service/sharddistributor/config"
)

// MockElector is a mock of Elector interface.
type MockElector struct {
	ctrl     *gomock.Controller
	recorder *MockElectorMockRecorder
	isgomock struct{}
}

// MockElectorMockRecorder is the mock recorder for MockElector.
type MockElectorMockRecorder struct {
	mock *MockElector
}

// NewMockElector creates a new mock instance.
func NewMockElector(ctrl *gomock.Controller) *MockElector {
	mock := &MockElector{ctrl: ctrl}
	mock.recorder = &MockElectorMockRecorder{mock}
	return mock
}

// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockElector) EXPECT() *MockElectorMockRecorder {
	return m.recorder
}

// Run mocks base method.
func (m *MockElector) Run(ctx context.Context) <-chan bool {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "Run", ctx)
	ret0, _ := ret[0].(<-chan bool)
	return ret0
}

// Run indicates an expected call of Run.
func (mr *MockElectorMockRecorder) Run(ctx any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Run", reflect.TypeOf((*MockElector)(nil).Run), ctx)
}

// MockFactory is a mock of Factory interface.
type MockFactory struct {
	ctrl     *gomock.Controller
	recorder *MockFactoryMockRecorder
	isgomock struct{}
}

// MockFactoryMockRecorder is the mock recorder for MockFactory.
type MockFactoryMockRecorder struct {
	mock *MockFactory
}

// NewMockFactory creates a new mock instance.
func NewMockFactory(ctrl *gomock.Controller) *MockFactory {
	mock := &MockFactory{ctrl: ctrl}
	mock.recorder = &MockFactoryMockRecorder{mock}
	return mock
}

// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockFactory) EXPECT() *MockFactoryMockRecorder {
	return m.recorder
}

// CreateElector mocks base method.
func (m *MockFactory) CreateElector(ctx context.Context, namespaceCfg config.Namespace) (Elector, error) {
	m.ctrl.T.Helper()
	ret := m.ctrl.Call(m, "CreateElector", ctx, namespaceCfg)
	ret0, _ := ret[0].(Elector)
	ret1, _ := ret[1].(error)
	return ret0, ret1
}

// CreateElector indicates an expected call of CreateElector.
func (mr *MockFactoryMockRecorder) CreateElector(ctx, namespaceCfg any) *gomock.Call {
	mr.mock.ctrl.T.Helper()
	return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateElector", reflect.TypeOf((*MockFactory)(nil).CreateElector), ctx, namespaceCfg)
}
