-
Notifications
You must be signed in to change notification settings - Fork 14
/
client.go
130 lines (112 loc) · 4.34 KB
/
client.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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
// Code generated by MockGen. DO NOT EDIT.
// Source: client.go
// Package mock is a generated GoMock package.
package mock
import (
context "context"
reflect "reflect"
gomock "go.uber.org/mock/gomock"
grpc "google.golang.org/grpc"
push "github.com/bucketeer-io/bucketeer/proto/push"
)
// MockClient is a mock of Client interface.
type MockClient struct {
ctrl *gomock.Controller
recorder *MockClientMockRecorder
}
// MockClientMockRecorder is the mock recorder for MockClient.
type MockClientMockRecorder struct {
mock *MockClient
}
// NewMockClient creates a new mock instance.
func NewMockClient(ctrl *gomock.Controller) *MockClient {
mock := &MockClient{ctrl: ctrl}
mock.recorder = &MockClientMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockClient) EXPECT() *MockClientMockRecorder {
return m.recorder
}
// Close mocks base method.
func (m *MockClient) Close() {
m.ctrl.T.Helper()
m.ctrl.Call(m, "Close")
}
// Close indicates an expected call of Close.
func (mr *MockClientMockRecorder) Close() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockClient)(nil).Close))
}
// CreatePush mocks base method.
func (m *MockClient) CreatePush(ctx context.Context, in *push.CreatePushRequest, opts ...grpc.CallOption) (*push.CreatePushResponse, error) {
m.ctrl.T.Helper()
varargs := []interface{}{ctx, in}
for _, a := range opts {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "CreatePush", varargs...)
ret0, _ := ret[0].(*push.CreatePushResponse)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// CreatePush indicates an expected call of CreatePush.
func (mr *MockClientMockRecorder) CreatePush(ctx, in interface{}, opts ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{ctx, in}, opts...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreatePush", reflect.TypeOf((*MockClient)(nil).CreatePush), varargs...)
}
// DeletePush mocks base method.
func (m *MockClient) DeletePush(ctx context.Context, in *push.DeletePushRequest, opts ...grpc.CallOption) (*push.DeletePushResponse, error) {
m.ctrl.T.Helper()
varargs := []interface{}{ctx, in}
for _, a := range opts {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "DeletePush", varargs...)
ret0, _ := ret[0].(*push.DeletePushResponse)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// DeletePush indicates an expected call of DeletePush.
func (mr *MockClientMockRecorder) DeletePush(ctx, in interface{}, opts ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{ctx, in}, opts...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeletePush", reflect.TypeOf((*MockClient)(nil).DeletePush), varargs...)
}
// ListPushes mocks base method.
func (m *MockClient) ListPushes(ctx context.Context, in *push.ListPushesRequest, opts ...grpc.CallOption) (*push.ListPushesResponse, error) {
m.ctrl.T.Helper()
varargs := []interface{}{ctx, in}
for _, a := range opts {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "ListPushes", varargs...)
ret0, _ := ret[0].(*push.ListPushesResponse)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// ListPushes indicates an expected call of ListPushes.
func (mr *MockClientMockRecorder) ListPushes(ctx, in interface{}, opts ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{ctx, in}, opts...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListPushes", reflect.TypeOf((*MockClient)(nil).ListPushes), varargs...)
}
// UpdatePush mocks base method.
func (m *MockClient) UpdatePush(ctx context.Context, in *push.UpdatePushRequest, opts ...grpc.CallOption) (*push.UpdatePushResponse, error) {
m.ctrl.T.Helper()
varargs := []interface{}{ctx, in}
for _, a := range opts {
varargs = append(varargs, a)
}
ret := m.ctrl.Call(m, "UpdatePush", varargs...)
ret0, _ := ret[0].(*push.UpdatePushResponse)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// UpdatePush indicates an expected call of UpdatePush.
func (mr *MockClientMockRecorder) UpdatePush(ctx, in interface{}, opts ...interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
varargs := append([]interface{}{ctx, in}, opts...)
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdatePush", reflect.TypeOf((*MockClient)(nil).UpdatePush), varargs...)
}