forked from aergoio/aergo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mock_messagehandler.go
101 lines (84 loc) · 3.47 KB
/
mock_messagehandler.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/aergoio/aergo/p2p/p2pcommon (interfaces: MessageHandler)
// Package mock_p2pcommon is a generated GoMock package.
package p2pmock
import (
reflect "reflect"
p2pcommon "github.com/aergoio/aergo/p2p/p2pcommon"
gomock "github.com/golang/mock/gomock"
proto "github.com/golang/protobuf/proto"
)
// MockMessageHandler is a mock of MessageHandler interface
type MockMessageHandler struct {
ctrl *gomock.Controller
recorder *MockMessageHandlerMockRecorder
}
// MockMessageHandlerMockRecorder is the mock recorder for MockMessageHandler
type MockMessageHandlerMockRecorder struct {
mock *MockMessageHandler
}
// NewMockMessageHandler creates a new mock instance
func NewMockMessageHandler(ctrl *gomock.Controller) *MockMessageHandler {
mock := &MockMessageHandler{ctrl: ctrl}
mock.recorder = &MockMessageHandlerMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use
func (m *MockMessageHandler) EXPECT() *MockMessageHandlerMockRecorder {
return m.recorder
}
// CheckAuth mocks base method
func (m *MockMessageHandler) CheckAuth(arg0 p2pcommon.Message, arg1 proto.Message) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CheckAuth", arg0, arg1)
ret0, _ := ret[0].(error)
return ret0
}
// CheckAuth indicates an expected call of CheckAuth
func (mr *MockMessageHandlerMockRecorder) CheckAuth(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CheckAuth", reflect.TypeOf((*MockMessageHandler)(nil).CheckAuth), arg0, arg1)
}
// Handle mocks base method
func (m *MockMessageHandler) Handle(arg0 p2pcommon.Message, arg1 proto.Message) {
m.ctrl.T.Helper()
m.ctrl.Call(m, "Handle", arg0, arg1)
}
// Handle indicates an expected call of Handle
func (mr *MockMessageHandlerMockRecorder) Handle(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Handle", reflect.TypeOf((*MockMessageHandler)(nil).Handle), arg0, arg1)
}
// ParsePayload mocks base method
func (m *MockMessageHandler) ParsePayload(arg0 []byte) (proto.Message, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "ParsePayload", arg0)
ret0, _ := ret[0].(proto.Message)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ParsePayload indicates an expected call of ParsePayload
func (mr *MockMessageHandlerMockRecorder) ParsePayload(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ParsePayload", reflect.TypeOf((*MockMessageHandler)(nil).ParsePayload), arg0)
}
// PostHandle mocks base method
func (m *MockMessageHandler) PostHandle(arg0 p2pcommon.Message, arg1 proto.Message) {
m.ctrl.T.Helper()
m.ctrl.Call(m, "PostHandle", arg0, arg1)
}
// PostHandle indicates an expected call of PostHandle
func (mr *MockMessageHandlerMockRecorder) PostHandle(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PostHandle", reflect.TypeOf((*MockMessageHandler)(nil).PostHandle), arg0, arg1)
}
// PreHandle mocks base method
func (m *MockMessageHandler) PreHandle() {
m.ctrl.T.Helper()
m.ctrl.Call(m, "PreHandle")
}
// PreHandle indicates an expected call of PreHandle
func (mr *MockMessageHandlerMockRecorder) PreHandle() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PreHandle", reflect.TypeOf((*MockMessageHandler)(nil).PreHandle))
}