-
Notifications
You must be signed in to change notification settings - Fork 175
/
follower_consumer.go
51 lines (38 loc) · 1.49 KB
/
follower_consumer.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
// Code generated by mockery v2.21.4. DO NOT EDIT.
package mocks
import (
flow "github.com/onflow/flow-go/model/flow"
mock "github.com/stretchr/testify/mock"
model "github.com/onflow/flow-go/consensus/hotstuff/model"
)
// FollowerConsumer is an autogenerated mock type for the FollowerConsumer type
type FollowerConsumer struct {
mock.Mock
}
// OnBlockIncorporated provides a mock function with given fields: _a0
func (_m *FollowerConsumer) OnBlockIncorporated(_a0 *model.Block) {
_m.Called(_a0)
}
// OnDoubleProposeDetected provides a mock function with given fields: _a0, _a1
func (_m *FollowerConsumer) OnDoubleProposeDetected(_a0 *model.Block, _a1 *model.Block) {
_m.Called(_a0, _a1)
}
// OnFinalizedBlock provides a mock function with given fields: _a0
func (_m *FollowerConsumer) OnFinalizedBlock(_a0 *model.Block) {
_m.Called(_a0)
}
// OnInvalidBlockDetected provides a mock function with given fields: err
func (_m *FollowerConsumer) OnInvalidBlockDetected(err flow.Slashable[model.InvalidProposalError]) {
_m.Called(err)
}
type mockConstructorTestingTNewFollowerConsumer interface {
mock.TestingT
Cleanup(func())
}
// NewFollowerConsumer creates a new instance of FollowerConsumer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func NewFollowerConsumer(t mockConstructorTestingTNewFollowerConsumer) *FollowerConsumer {
mock := &FollowerConsumer{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}