forked from nikoksr/notify
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mock_wechat_message_manager.go
81 lines (64 loc) · 2.35 KB
/
mock_wechat_message_manager.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
// Code generated by mockery v2.43.2. DO NOT EDIT.
package wechat
import (
message "github.com/silenceper/wechat/v2/officialaccount/message"
mock "github.com/stretchr/testify/mock"
)
// mockwechatMessageManager is an autogenerated mock type for the wechatMessageManager type
type mockwechatMessageManager struct {
mock.Mock
}
type mockwechatMessageManager_Expecter struct {
mock *mock.Mock
}
func (_m *mockwechatMessageManager) EXPECT() *mockwechatMessageManager_Expecter {
return &mockwechatMessageManager_Expecter{mock: &_m.Mock}
}
// Send provides a mock function with given fields: msg
func (_m *mockwechatMessageManager) Send(msg *message.CustomerMessage) error {
ret := _m.Called(msg)
if len(ret) == 0 {
panic("no return value specified for Send")
}
var r0 error
if rf, ok := ret.Get(0).(func(*message.CustomerMessage) error); ok {
r0 = rf(msg)
} else {
r0 = ret.Error(0)
}
return r0
}
// mockwechatMessageManager_Send_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Send'
type mockwechatMessageManager_Send_Call struct {
*mock.Call
}
// Send is a helper method to define mock.On call
// - msg *message.CustomerMessage
func (_e *mockwechatMessageManager_Expecter) Send(msg interface{}) *mockwechatMessageManager_Send_Call {
return &mockwechatMessageManager_Send_Call{Call: _e.mock.On("Send", msg)}
}
func (_c *mockwechatMessageManager_Send_Call) Run(run func(msg *message.CustomerMessage)) *mockwechatMessageManager_Send_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*message.CustomerMessage))
})
return _c
}
func (_c *mockwechatMessageManager_Send_Call) Return(_a0 error) *mockwechatMessageManager_Send_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *mockwechatMessageManager_Send_Call) RunAndReturn(run func(*message.CustomerMessage) error) *mockwechatMessageManager_Send_Call {
_c.Call.Return(run)
return _c
}
// newMockwechatMessageManager creates a new instance of mockwechatMessageManager. 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 newMockwechatMessageManager(t interface {
mock.TestingT
Cleanup(func())
}) *mockwechatMessageManager {
mock := &mockwechatMessageManager{}
mock.Mock.Test(t)
t.Cleanup(func() { mock.AssertExpectations(t) })
return mock
}