zitadel/internal/crypto/crypto_mock.go

229 lines
7.4 KiB
Go
Raw Normal View History

2020-03-23 07:06:44 +01:00
// Code generated by MockGen. DO NOT EDIT.
// Source: crypto.go
//
// Generated by this command:
//
// mockgen -source crypto.go -destination ./crypto_mock.go -package crypto
//
2020-03-23 07:06:44 +01:00
// Package crypto is a generated GoMock package.
package crypto
import (
reflect "reflect"
gomock "go.uber.org/mock/gomock"
2020-03-23 07:06:44 +01:00
)
// MockCrypto is a mock of Crypto interface.
2020-03-23 07:06:44 +01:00
type MockCrypto struct {
ctrl *gomock.Controller
recorder *MockCryptoMockRecorder
}
// MockCryptoMockRecorder is the mock recorder for MockCrypto.
2020-03-23 07:06:44 +01:00
type MockCryptoMockRecorder struct {
mock *MockCrypto
}
// NewMockCrypto creates a new mock instance.
2020-03-23 07:06:44 +01:00
func NewMockCrypto(ctrl *gomock.Controller) *MockCrypto {
mock := &MockCrypto{ctrl: ctrl}
mock.recorder = &MockCryptoMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
2020-03-23 07:06:44 +01:00
func (m *MockCrypto) EXPECT() *MockCryptoMockRecorder {
return m.recorder
}
// Algorithm mocks base method.
2020-03-23 07:06:44 +01:00
func (m *MockCrypto) Algorithm() string {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Algorithm")
ret0, _ := ret[0].(string)
return ret0
}
// Algorithm indicates an expected call of Algorithm.
2020-03-23 07:06:44 +01:00
func (mr *MockCryptoMockRecorder) Algorithm() *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Algorithm", reflect.TypeOf((*MockCrypto)(nil).Algorithm))
}
// MockEncryptionAlgorithm is a mock of EncryptionAlgorithm interface.
2020-03-30 09:28:00 +02:00
type MockEncryptionAlgorithm struct {
2020-03-23 07:06:44 +01:00
ctrl *gomock.Controller
2020-03-30 09:28:00 +02:00
recorder *MockEncryptionAlgorithmMockRecorder
2020-03-23 07:06:44 +01:00
}
// MockEncryptionAlgorithmMockRecorder is the mock recorder for MockEncryptionAlgorithm.
2020-03-30 09:28:00 +02:00
type MockEncryptionAlgorithmMockRecorder struct {
mock *MockEncryptionAlgorithm
2020-03-23 07:06:44 +01:00
}
// NewMockEncryptionAlgorithm creates a new mock instance.
2020-03-30 09:28:00 +02:00
func NewMockEncryptionAlgorithm(ctrl *gomock.Controller) *MockEncryptionAlgorithm {
mock := &MockEncryptionAlgorithm{ctrl: ctrl}
mock.recorder = &MockEncryptionAlgorithmMockRecorder{mock}
2020-03-23 07:06:44 +01:00
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
2020-03-30 09:28:00 +02:00
func (m *MockEncryptionAlgorithm) EXPECT() *MockEncryptionAlgorithmMockRecorder {
2020-03-23 07:06:44 +01:00
return m.recorder
}
// Algorithm mocks base method.
2020-03-30 09:28:00 +02:00
func (m *MockEncryptionAlgorithm) Algorithm() string {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Algorithm")
ret0, _ := ret[0].(string)
return ret0
}
// Algorithm indicates an expected call of Algorithm.
2020-03-30 09:28:00 +02:00
func (mr *MockEncryptionAlgorithmMockRecorder) Algorithm() *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
2020-03-30 09:28:00 +02:00
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Algorithm", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).Algorithm))
2020-03-23 07:06:44 +01:00
}
// Decrypt mocks base method.
func (m *MockEncryptionAlgorithm) Decrypt(hashed []byte, keyID string) ([]byte, error) {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Decrypt", hashed, keyID)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Decrypt indicates an expected call of Decrypt.
func (mr *MockEncryptionAlgorithmMockRecorder) Decrypt(hashed, keyID any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Decrypt", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).Decrypt), hashed, keyID)
}
// DecryptString mocks base method.
func (m *MockEncryptionAlgorithm) DecryptString(hashed []byte, keyID string) (string, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "DecryptString", hashed, keyID)
2020-03-23 07:06:44 +01:00
ret0, _ := ret[0].(string)
ret1, _ := ret[1].(error)
return ret0, ret1
2020-03-23 07:06:44 +01:00
}
// DecryptString indicates an expected call of DecryptString.
func (mr *MockEncryptionAlgorithmMockRecorder) DecryptString(hashed, keyID any) *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DecryptString", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).DecryptString), hashed, keyID)
2020-03-23 07:06:44 +01:00
}
// DecryptionKeyIDs mocks base method.
2020-03-30 09:28:00 +02:00
func (m *MockEncryptionAlgorithm) DecryptionKeyIDs() []string {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "DecryptionKeyIDs")
ret0, _ := ret[0].([]string)
return ret0
}
// DecryptionKeyIDs indicates an expected call of DecryptionKeyIDs.
2020-03-30 09:28:00 +02:00
func (mr *MockEncryptionAlgorithmMockRecorder) DecryptionKeyIDs() *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
2020-03-30 09:28:00 +02:00
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DecryptionKeyIDs", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).DecryptionKeyIDs))
2020-03-23 07:06:44 +01:00
}
// Encrypt mocks base method.
2020-03-30 09:28:00 +02:00
func (m *MockEncryptionAlgorithm) Encrypt(value []byte) ([]byte, error) {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Encrypt", value)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Encrypt indicates an expected call of Encrypt.
func (mr *MockEncryptionAlgorithmMockRecorder) Encrypt(value any) *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
2020-03-30 09:28:00 +02:00
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Encrypt", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).Encrypt), value)
2020-03-23 07:06:44 +01:00
}
// EncryptionKeyID mocks base method.
func (m *MockEncryptionAlgorithm) EncryptionKeyID() string {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "EncryptionKeyID")
2020-03-23 07:06:44 +01:00
ret0, _ := ret[0].(string)
return ret0
2020-03-23 07:06:44 +01:00
}
// EncryptionKeyID indicates an expected call of EncryptionKeyID.
func (mr *MockEncryptionAlgorithmMockRecorder) EncryptionKeyID() *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "EncryptionKeyID", reflect.TypeOf((*MockEncryptionAlgorithm)(nil).EncryptionKeyID))
2020-03-23 07:06:44 +01:00
}
// MockHashAlgorithm is a mock of HashAlgorithm interface.
2020-03-30 09:28:00 +02:00
type MockHashAlgorithm struct {
2020-03-23 07:06:44 +01:00
ctrl *gomock.Controller
2020-03-30 09:28:00 +02:00
recorder *MockHashAlgorithmMockRecorder
2020-03-23 07:06:44 +01:00
}
// MockHashAlgorithmMockRecorder is the mock recorder for MockHashAlgorithm.
2020-03-30 09:28:00 +02:00
type MockHashAlgorithmMockRecorder struct {
mock *MockHashAlgorithm
2020-03-23 07:06:44 +01:00
}
// NewMockHashAlgorithm creates a new mock instance.
2020-03-30 09:28:00 +02:00
func NewMockHashAlgorithm(ctrl *gomock.Controller) *MockHashAlgorithm {
mock := &MockHashAlgorithm{ctrl: ctrl}
mock.recorder = &MockHashAlgorithmMockRecorder{mock}
2020-03-23 07:06:44 +01:00
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
2020-03-30 09:28:00 +02:00
func (m *MockHashAlgorithm) EXPECT() *MockHashAlgorithmMockRecorder {
2020-03-23 07:06:44 +01:00
return m.recorder
}
// Algorithm mocks base method.
2020-03-30 09:28:00 +02:00
func (m *MockHashAlgorithm) Algorithm() string {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Algorithm")
ret0, _ := ret[0].(string)
return ret0
}
// Algorithm indicates an expected call of Algorithm.
2020-03-30 09:28:00 +02:00
func (mr *MockHashAlgorithmMockRecorder) Algorithm() *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
2020-03-30 09:28:00 +02:00
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Algorithm", reflect.TypeOf((*MockHashAlgorithm)(nil).Algorithm))
2020-03-23 07:06:44 +01:00
}
// CompareHash mocks base method.
func (m *MockHashAlgorithm) CompareHash(hashed, comparer []byte) error {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "CompareHash", hashed, comparer)
ret0, _ := ret[0].(error)
return ret0
2020-03-23 07:06:44 +01:00
}
// CompareHash indicates an expected call of CompareHash.
func (mr *MockHashAlgorithmMockRecorder) CompareHash(hashed, comparer any) *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CompareHash", reflect.TypeOf((*MockHashAlgorithm)(nil).CompareHash), hashed, comparer)
2020-03-23 07:06:44 +01:00
}
// Hash mocks base method.
func (m *MockHashAlgorithm) Hash(value []byte) ([]byte, error) {
2020-03-23 07:06:44 +01:00
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Hash", value)
ret0, _ := ret[0].([]byte)
ret1, _ := ret[1].(error)
return ret0, ret1
2020-03-23 07:06:44 +01:00
}
// Hash indicates an expected call of Hash.
func (mr *MockHashAlgorithmMockRecorder) Hash(value any) *gomock.Call {
2020-03-23 07:06:44 +01:00
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Hash", reflect.TypeOf((*MockHashAlgorithm)(nil).Hash), value)
2020-03-23 07:06:44 +01:00
}