-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmocks.go
85 lines (72 loc) · 2.5 KB
/
mocks.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
// Code generated by MockGen. DO NOT EDIT.
// Source: store.go
// Package ratelimiter is a generated GoMock package.
package ratelimiter
import (
context "context"
reflect "reflect"
gomock "github.com/golang/mock/gomock"
)
// MockStore is a mock of Store interface.
type MockStore struct {
ctrl *gomock.Controller
recorder *MockStoreMockRecorder
}
// MockStoreMockRecorder is the mock recorder for MockStore.
type MockStoreMockRecorder struct {
mock *MockStore
}
// NewMockStore creates a new mock instance.
func NewMockStore(ctrl *gomock.Controller) *MockStore {
mock := &MockStore{ctrl: ctrl}
mock.recorder = &MockStoreMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockStore) EXPECT() *MockStoreMockRecorder {
return m.recorder
}
// Reset mocks base method.
func (m *MockStore) Reset(ctx context.Context) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Reset", ctx)
ret0, _ := ret[0].(error)
return ret0
}
// Reset indicates an expected call of Reset.
func (mr *MockStoreMockRecorder) Reset(ctx interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Reset", reflect.TypeOf((*MockStore)(nil).Reset), ctx)
}
// Take mocks base method.
func (m *MockStore) Take(ctx context.Context, key string) (uint64, uint64, uint64, bool, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Take", ctx, key)
ret0, _ := ret[0].(uint64)
ret1, _ := ret[1].(uint64)
ret2, _ := ret[2].(uint64)
ret3, _ := ret[3].(bool)
ret4, _ := ret[4].(error)
return ret0, ret1, ret2, ret3, ret4
}
// Take indicates an expected call of Take.
func (mr *MockStoreMockRecorder) Take(ctx, key interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Take", reflect.TypeOf((*MockStore)(nil).Take), ctx, key)
}
// TakeExcl mocks base method.
func (m *MockStore) TakeExcl(ctx context.Context, key string, f ExclFunc) (uint64, uint64, uint64, bool, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "TakeExcl", ctx, key, f)
ret0, _ := ret[0].(uint64)
ret1, _ := ret[1].(uint64)
ret2, _ := ret[2].(uint64)
ret3, _ := ret[3].(bool)
ret4, _ := ret[4].(error)
return ret0, ret1, ret2, ret3, ret4
}
// TakeExcl indicates an expected call of TakeExcl.
func (mr *MockStoreMockRecorder) TakeExcl(ctx, key, f interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "TakeExcl", reflect.TypeOf((*MockStore)(nil).TakeExcl), ctx, key, f)
}