/
gossiper.go
59 lines (46 loc) · 1.94 KB
/
gossiper.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
52
53
54
55
56
57
58
59
// Code generated by mockery. DO NOT EDIT.
package mocks
import (
context "context"
types "github.com/dashpay/tenderdash/internal/consensus/types"
mock "github.com/stretchr/testify/mock"
)
// Gossiper is an autogenerated mock type for the Gossiper type
type Gossiper struct {
mock.Mock
}
// GossipBlockPartsForCatchup provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipBlockPartsForCatchup(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// GossipCommit provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipCommit(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// GossipProposal provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipProposal(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// GossipProposalBlockParts provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipProposalBlockParts(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// GossipVote provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipVote(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// GossipVoteSetMaj23 provides a mock function with given fields: ctx, rs, prs
func (_m *Gossiper) GossipVoteSetMaj23(ctx context.Context, rs types.RoundState, prs *types.PeerRoundState) {
_m.Called(ctx, rs, prs)
}
// NewGossiper creates a new instance of Gossiper. 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 NewGossiper(t interface {
mock.TestingT
Cleanup(func())
}) *Gossiper {
mock := &Gossiper{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}