github.com/onflow/flow-go@v0.35.7-crescendo-preview.23-atree-inlining/module/mock/hot_stuff_follower.go (about) 1 // Code generated by mockery v2.21.4. DO NOT EDIT. 2 3 package mock 4 5 import ( 6 irrecoverable "github.com/onflow/flow-go/module/irrecoverable" 7 mock "github.com/stretchr/testify/mock" 8 9 model "github.com/onflow/flow-go/consensus/hotstuff/model" 10 ) 11 12 // HotStuffFollower is an autogenerated mock type for the HotStuffFollower type 13 type HotStuffFollower struct { 14 mock.Mock 15 } 16 17 // AddCertifiedBlock provides a mock function with given fields: certifiedBlock 18 func (_m *HotStuffFollower) AddCertifiedBlock(certifiedBlock *model.CertifiedBlock) { 19 _m.Called(certifiedBlock) 20 } 21 22 // Done provides a mock function with given fields: 23 func (_m *HotStuffFollower) Done() <-chan struct{} { 24 ret := _m.Called() 25 26 var r0 <-chan struct{} 27 if rf, ok := ret.Get(0).(func() <-chan struct{}); ok { 28 r0 = rf() 29 } else { 30 if ret.Get(0) != nil { 31 r0 = ret.Get(0).(<-chan struct{}) 32 } 33 } 34 35 return r0 36 } 37 38 // Ready provides a mock function with given fields: 39 func (_m *HotStuffFollower) Ready() <-chan struct{} { 40 ret := _m.Called() 41 42 var r0 <-chan struct{} 43 if rf, ok := ret.Get(0).(func() <-chan struct{}); ok { 44 r0 = rf() 45 } else { 46 if ret.Get(0) != nil { 47 r0 = ret.Get(0).(<-chan struct{}) 48 } 49 } 50 51 return r0 52 } 53 54 // Start provides a mock function with given fields: _a0 55 func (_m *HotStuffFollower) Start(_a0 irrecoverable.SignalerContext) { 56 _m.Called(_a0) 57 } 58 59 type mockConstructorTestingTNewHotStuffFollower interface { 60 mock.TestingT 61 Cleanup(func()) 62 } 63 64 // NewHotStuffFollower creates a new instance of HotStuffFollower. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 65 func NewHotStuffFollower(t mockConstructorTestingTNewHotStuffFollower) *HotStuffFollower { 66 mock := &HotStuffFollower{} 67 mock.Mock.Test(t) 68 69 t.Cleanup(func() { mock.AssertExpectations(t) }) 70 71 return mock 72 }