// Code generated by mockery. DO NOT EDIT. package mocks import ( mock "github.com/stretchr/testify/mock" models "source.quilibrium.com/quilibrium/monorepo/consensus/models" ) // Validator is an autogenerated mock type for the Validator type type Validator[StateT models.Unique, VoteT models.Unique] struct { mock.Mock } // ValidateProposal provides a mock function with given fields: proposal func (_m *Validator[StateT, VoteT]) ValidateProposal(proposal *models.SignedProposal[StateT, VoteT]) error { ret := _m.Called(proposal) if len(ret) == 0 { panic("no return value specified for ValidateProposal") } var r0 error if rf, ok := ret.Get(0).(func(*models.SignedProposal[StateT, VoteT]) error); ok { r0 = rf(proposal) } else { r0 = ret.Error(0) } return r0 } // ValidateQuorumCertificate provides a mock function with given fields: qc func (_m *Validator[StateT, VoteT]) ValidateQuorumCertificate(qc models.QuorumCertificate) error { ret := _m.Called(qc) if len(ret) == 0 { panic("no return value specified for ValidateQuorumCertificate") } var r0 error if rf, ok := ret.Get(0).(func(models.QuorumCertificate) error); ok { r0 = rf(qc) } else { r0 = ret.Error(0) } return r0 } // ValidateTimeoutCertificate provides a mock function with given fields: tc func (_m *Validator[StateT, VoteT]) ValidateTimeoutCertificate(tc models.TimeoutCertificate) error { ret := _m.Called(tc) if len(ret) == 0 { panic("no return value specified for ValidateTimeoutCertificate") } var r0 error if rf, ok := ret.Get(0).(func(models.TimeoutCertificate) error); ok { r0 = rf(tc) } else { r0 = ret.Error(0) } return r0 } // ValidateVote provides a mock function with given fields: vote func (_m *Validator[StateT, VoteT]) ValidateVote(vote *VoteT) (*models.WeightedIdentity, error) { ret := _m.Called(vote) if len(ret) == 0 { panic("no return value specified for ValidateVote") } var r0 *models.WeightedIdentity var r1 error if rf, ok := ret.Get(0).(func(*VoteT) (*models.WeightedIdentity, error)); ok { return rf(vote) } if rf, ok := ret.Get(0).(func(*VoteT) *models.WeightedIdentity); ok { r0 = rf(vote) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*models.WeightedIdentity) } } if rf, ok := ret.Get(1).(func(*VoteT) error); ok { r1 = rf(vote) } else { r1 = ret.Error(1) } return r0, r1 } // NewValidator creates a new instance of Validator. 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 NewValidator[StateT models.Unique, VoteT models.Unique](t interface { mock.TestingT Cleanup(func()) }) *Validator[StateT, VoteT] { mock := &Validator[StateT, VoteT]{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) }) return mock }