-
Notifications
You must be signed in to change notification settings - Fork 43
/
auth.go
91 lines (77 loc) · 2.69 KB
/
auth.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
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/baetyl/baetyl-cloud/plugin (interfaces: Auth)
// Package plugin is a generated GoMock package.
package plugin
import (
common "github.com/baetyl/baetyl-cloud/common"
gomock "github.com/golang/mock/gomock"
reflect "reflect"
)
// MockAuth is a mock of Auth interface
type MockAuth struct {
ctrl *gomock.Controller
recorder *MockAuthMockRecorder
}
// MockAuthMockRecorder is the mock recorder for MockAuth
type MockAuthMockRecorder struct {
mock *MockAuth
}
// NewMockAuth creates a new mock instance
func NewMockAuth(ctrl *gomock.Controller) *MockAuth {
mock := &MockAuth{ctrl: ctrl}
mock.recorder = &MockAuthMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use
func (m *MockAuth) EXPECT() *MockAuthMockRecorder {
return m.recorder
}
// Authenticate mocks base method
func (m *MockAuth) Authenticate(arg0 *common.Context) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Authenticate", arg0)
ret0, _ := ret[0].(error)
return ret0
}
// Authenticate indicates an expected call of Authenticate
func (mr *MockAuthMockRecorder) Authenticate(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Authenticate", reflect.TypeOf((*MockAuth)(nil).Authenticate), arg0)
}
// Close mocks base method
func (m *MockAuth) Close() error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Close")
ret0, _ := ret[0].(error)
return ret0
}
// Close indicates an expected call of Close
func (mr *MockAuthMockRecorder) Close() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Close", reflect.TypeOf((*MockAuth)(nil).Close))
}
// SignToken mocks base method
func (m *MockAuth) SignToken(arg0 []byte) ([]byte, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "SignToken", arg0)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// SignToken indicates an expected call of SignToken
func (mr *MockAuthMockRecorder) SignToken(arg0 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SignToken", reflect.TypeOf((*MockAuth)(nil).SignToken), arg0)
}
// VerifyToken mocks base method
func (m *MockAuth) VerifyToken(arg0, arg1 []byte) bool {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "VerifyToken", arg0, arg1)
ret0, _ := ret[0].(bool)
return ret0
}
// VerifyToken indicates an expected call of VerifyToken
func (mr *MockAuthMockRecorder) VerifyToken(arg0, arg1 interface{}) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "VerifyToken", reflect.TypeOf((*MockAuth)(nil).VerifyToken), arg0, arg1)
}