mirror of
https://github.com/rancher/steve.git
synced 2025-09-02 07:55:31 +00:00
Bumped dependencies to be compatible with k8s-v1.33 (#681)
Signed-off-by: swastik959 <Sswastik959@gmail.com>
This commit is contained in:
@@ -21,6 +21,7 @@ import (
|
||||
type MockRows struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockRowsMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockRowsMockRecorder is the mock recorder for MockRows.
|
||||
@@ -83,10 +84,10 @@ func (mr *MockRowsMockRecorder) Next() *gomock.Call {
|
||||
}
|
||||
|
||||
// Scan mocks base method.
|
||||
func (m *MockRows) Scan(arg0 ...any) error {
|
||||
func (m *MockRows) Scan(dest ...any) error {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range dest {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Scan", varargs...)
|
||||
@@ -95,15 +96,16 @@ func (m *MockRows) Scan(arg0 ...any) error {
|
||||
}
|
||||
|
||||
// Scan indicates an expected call of Scan.
|
||||
func (mr *MockRowsMockRecorder) Scan(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockRowsMockRecorder) Scan(dest ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), dest...)
|
||||
}
|
||||
|
||||
// MockConnection is a mock of Connection interface.
|
||||
type MockConnection struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockConnectionMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockConnectionMockRecorder is the mock recorder for MockConnection.
|
||||
@@ -124,18 +126,18 @@ func (m *MockConnection) EXPECT() *MockConnectionMockRecorder {
|
||||
}
|
||||
|
||||
// BeginTx mocks base method.
|
||||
func (m *MockConnection) BeginTx(arg0 context.Context, arg1 *sql.TxOptions) (*sql.Tx, error) {
|
||||
func (m *MockConnection) BeginTx(ctx context.Context, opts *sql.TxOptions) (*sql.Tx, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "BeginTx", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "BeginTx", ctx, opts)
|
||||
ret0, _ := ret[0].(*sql.Tx)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// BeginTx indicates an expected call of BeginTx.
|
||||
func (mr *MockConnectionMockRecorder) BeginTx(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockConnectionMockRecorder) BeginTx(ctx, opts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BeginTx", reflect.TypeOf((*MockConnection)(nil).BeginTx), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BeginTx", reflect.TypeOf((*MockConnection)(nil).BeginTx), ctx, opts)
|
||||
}
|
||||
|
||||
// Close mocks base method.
|
||||
@@ -153,10 +155,10 @@ func (mr *MockConnectionMockRecorder) Close() *gomock.Call {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockConnection) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
func (m *MockConnection) Exec(query string, args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{query}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -166,31 +168,32 @@ func (m *MockConnection) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockConnectionMockRecorder) Exec(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockConnectionMockRecorder) Exec(query any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{query}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockConnection)(nil).Exec), varargs...)
|
||||
}
|
||||
|
||||
// Prepare mocks base method.
|
||||
func (m *MockConnection) Prepare(arg0 string) (*sql.Stmt, error) {
|
||||
func (m *MockConnection) Prepare(query string) (*sql.Stmt, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Prepare", arg0)
|
||||
ret := m.ctrl.Call(m, "Prepare", query)
|
||||
ret0, _ := ret[0].(*sql.Stmt)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// Prepare indicates an expected call of Prepare.
|
||||
func (mr *MockConnectionMockRecorder) Prepare(arg0 any) *gomock.Call {
|
||||
func (mr *MockConnectionMockRecorder) Prepare(query any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockConnection)(nil).Prepare), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockConnection)(nil).Prepare), query)
|
||||
}
|
||||
|
||||
// MockEncryptor is a mock of Encryptor interface.
|
||||
type MockEncryptor struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockEncryptorMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockEncryptorMockRecorder is the mock recorder for MockEncryptor.
|
||||
@@ -231,6 +234,7 @@ func (mr *MockEncryptorMockRecorder) Encrypt(arg0 any) *gomock.Call {
|
||||
type MockDecryptor struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockDecryptorMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockDecryptorMockRecorder is the mock recorder for MockDecryptor.
|
||||
|
@@ -22,6 +22,7 @@ import (
|
||||
type MockClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockClientMockRecorder is the mock recorder for MockClient.
|
||||
@@ -42,10 +43,10 @@ func (m *MockClient) EXPECT() *MockClientMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
func (m *MockClient) Exec(query string, args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{query}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -55,30 +56,31 @@ func (m *MockClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockClientMockRecorder) Exec(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Exec(query any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{query}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockClient)(nil).Exec), varargs...)
|
||||
}
|
||||
|
||||
// Stmt mocks base method.
|
||||
func (m *MockClient) Stmt(arg0 *sql.Stmt) transaction.Stmt {
|
||||
func (m *MockClient) Stmt(stmt *sql.Stmt) transaction.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Stmt", arg0)
|
||||
ret := m.ctrl.Call(m, "Stmt", stmt)
|
||||
ret0, _ := ret[0].(transaction.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Stmt indicates an expected call of Stmt.
|
||||
func (mr *MockClientMockRecorder) Stmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Stmt(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockClient)(nil).Stmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockClient)(nil).Stmt), stmt)
|
||||
}
|
||||
|
||||
// MockStmt is a mock of Stmt interface.
|
||||
type MockStmt struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockStmtMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockStmtMockRecorder is the mock recorder for MockStmt.
|
||||
@@ -99,10 +101,10 @@ func (m *MockStmt) EXPECT() *MockStmtMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
func (m *MockStmt) Exec(args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -112,16 +114,16 @@ func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockStmtMockRecorder) Exec(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Exec(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), args...)
|
||||
}
|
||||
|
||||
// Query mocks base method.
|
||||
func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) Query(args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Query", varargs...)
|
||||
@@ -131,16 +133,16 @@ func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
}
|
||||
|
||||
// Query indicates an expected call of Query.
|
||||
func (mr *MockStmtMockRecorder) Query(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Query(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), args...)
|
||||
}
|
||||
|
||||
// QueryContext mocks base method.
|
||||
func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) QueryContext(ctx context.Context, args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryContext", varargs...)
|
||||
@@ -150,17 +152,17 @@ func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, e
|
||||
}
|
||||
|
||||
// QueryContext indicates an expected call of QueryContext.
|
||||
func (mr *MockStmtMockRecorder) QueryContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryContext", reflect.TypeOf((*MockStmt)(nil).QueryContext), varargs...)
|
||||
}
|
||||
|
||||
// QueryRowContext mocks base method.
|
||||
func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
func (m *MockStmt) QueryRowContext(ctx context.Context, args ...any) *sql.Row {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryRowContext", varargs...)
|
||||
@@ -169,8 +171,8 @@ func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
}
|
||||
|
||||
// QueryRowContext indicates an expected call of QueryRowContext.
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryRowContext", reflect.TypeOf((*MockStmt)(nil).QueryRowContext), varargs...)
|
||||
}
|
||||
|
@@ -23,6 +23,7 @@ import (
|
||||
type MockRows struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockRowsMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockRowsMockRecorder is the mock recorder for MockRows.
|
||||
@@ -85,10 +86,10 @@ func (mr *MockRowsMockRecorder) Next() *gomock.Call {
|
||||
}
|
||||
|
||||
// Scan mocks base method.
|
||||
func (m *MockRows) Scan(arg0 ...any) error {
|
||||
func (m *MockRows) Scan(dest ...any) error {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range dest {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Scan", varargs...)
|
||||
@@ -97,15 +98,16 @@ func (m *MockRows) Scan(arg0 ...any) error {
|
||||
}
|
||||
|
||||
// Scan indicates an expected call of Scan.
|
||||
func (mr *MockRowsMockRecorder) Scan(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockRowsMockRecorder) Scan(dest ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), dest...)
|
||||
}
|
||||
|
||||
// MockClient is a mock of Client interface.
|
||||
type MockClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockClientMockRecorder is the mock recorder for MockClient.
|
||||
@@ -126,53 +128,53 @@ func (m *MockClient) EXPECT() *MockClientMockRecorder {
|
||||
}
|
||||
|
||||
// CloseStmt mocks base method.
|
||||
func (m *MockClient) CloseStmt(arg0 db.Closable) error {
|
||||
func (m *MockClient) CloseStmt(closable db.Closable) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "CloseStmt", arg0)
|
||||
ret := m.ctrl.Call(m, "CloseStmt", closable)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// CloseStmt indicates an expected call of CloseStmt.
|
||||
func (mr *MockClientMockRecorder) CloseStmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) CloseStmt(closable any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), closable)
|
||||
}
|
||||
|
||||
// NewConnection mocks base method.
|
||||
func (m *MockClient) NewConnection(arg0 bool) (string, error) {
|
||||
func (m *MockClient) NewConnection(isTemp bool) (string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "NewConnection", arg0)
|
||||
ret := m.ctrl.Call(m, "NewConnection", isTemp)
|
||||
ret0, _ := ret[0].(string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// NewConnection indicates an expected call of NewConnection.
|
||||
func (mr *MockClientMockRecorder) NewConnection(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) NewConnection(isTemp any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), isTemp)
|
||||
}
|
||||
|
||||
// Prepare mocks base method.
|
||||
func (m *MockClient) Prepare(arg0 string) *sql.Stmt {
|
||||
func (m *MockClient) Prepare(stmt string) *sql.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Prepare", arg0)
|
||||
ret := m.ctrl.Call(m, "Prepare", stmt)
|
||||
ret0, _ := ret[0].(*sql.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Prepare indicates an expected call of Prepare.
|
||||
func (mr *MockClientMockRecorder) Prepare(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Prepare(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), stmt)
|
||||
}
|
||||
|
||||
// QueryForRows mocks base method.
|
||||
func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, arg2 ...any) (*sql.Rows, error) {
|
||||
func (m *MockClient) QueryForRows(ctx context.Context, stmt transaction.Stmt, params ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1}
|
||||
for _, a := range arg2 {
|
||||
varargs := []any{ctx, stmt}
|
||||
for _, a := range params {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryForRows", varargs...)
|
||||
@@ -182,81 +184,81 @@ func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, a
|
||||
}
|
||||
|
||||
// QueryForRows indicates an expected call of QueryForRows.
|
||||
func (mr *MockClientMockRecorder) QueryForRows(arg0, arg1 any, arg2 ...any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) QueryForRows(ctx, stmt any, params ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1}, arg2...)
|
||||
varargs := append([]any{ctx, stmt}, params...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryForRows", reflect.TypeOf((*MockClient)(nil).QueryForRows), varargs...)
|
||||
}
|
||||
|
||||
// ReadInt mocks base method.
|
||||
func (m *MockClient) ReadInt(arg0 db.Rows) (int, error) {
|
||||
func (m *MockClient) ReadInt(rows db.Rows) (int, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadInt", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadInt", rows)
|
||||
ret0, _ := ret[0].(int)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadInt indicates an expected call of ReadInt.
|
||||
func (mr *MockClientMockRecorder) ReadInt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadInt(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), rows)
|
||||
}
|
||||
|
||||
// ReadObjects mocks base method.
|
||||
func (m *MockClient) ReadObjects(arg0 db.Rows, arg1 reflect.Type, arg2 bool) ([]any, error) {
|
||||
func (m *MockClient) ReadObjects(rows db.Rows, typ reflect.Type, shouldDecrypt bool) ([]any, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadObjects", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "ReadObjects", rows, typ, shouldDecrypt)
|
||||
ret0, _ := ret[0].([]any)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadObjects indicates an expected call of ReadObjects.
|
||||
func (mr *MockClientMockRecorder) ReadObjects(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadObjects(rows, typ, shouldDecrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), rows, typ, shouldDecrypt)
|
||||
}
|
||||
|
||||
// ReadStrings mocks base method.
|
||||
func (m *MockClient) ReadStrings(arg0 db.Rows) ([]string, error) {
|
||||
func (m *MockClient) ReadStrings(rows db.Rows) ([]string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadStrings", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadStrings", rows)
|
||||
ret0, _ := ret[0].([]string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadStrings indicates an expected call of ReadStrings.
|
||||
func (mr *MockClientMockRecorder) ReadStrings(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadStrings(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), rows)
|
||||
}
|
||||
|
||||
// Upsert mocks base method.
|
||||
func (m *MockClient) Upsert(arg0 transaction.Client, arg1 *sql.Stmt, arg2 string, arg3 any, arg4 bool) error {
|
||||
func (m *MockClient) Upsert(tx transaction.Client, stmt *sql.Stmt, key string, obj any, shouldEncrypt bool) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Upsert", arg0, arg1, arg2, arg3, arg4)
|
||||
ret := m.ctrl.Call(m, "Upsert", tx, stmt, key, obj, shouldEncrypt)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Upsert indicates an expected call of Upsert.
|
||||
func (mr *MockClientMockRecorder) Upsert(arg0, arg1, arg2, arg3, arg4 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Upsert(tx, stmt, key, obj, shouldEncrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), arg0, arg1, arg2, arg3, arg4)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), tx, stmt, key, obj, shouldEncrypt)
|
||||
}
|
||||
|
||||
// WithTransaction mocks base method.
|
||||
func (m *MockClient) WithTransaction(arg0 context.Context, arg1 bool, arg2 db.WithTransactionFunction) error {
|
||||
func (m *MockClient) WithTransaction(ctx context.Context, forWriting bool, f db.WithTransactionFunction) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "WithTransaction", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "WithTransaction", ctx, forWriting, f)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// WithTransaction indicates an expected call of WithTransaction.
|
||||
func (mr *MockClientMockRecorder) WithTransaction(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) WithTransaction(ctx, forWriting, f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), ctx, forWriting, f)
|
||||
}
|
||||
|
@@ -24,6 +24,7 @@ import (
|
||||
type MockResourceInterface struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockResourceInterfaceMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockResourceInterfaceMockRecorder is the mock recorder for MockResourceInterface.
|
||||
@@ -44,10 +45,10 @@ func (m *MockResourceInterface) EXPECT() *MockResourceInterfaceMockRecorder {
|
||||
}
|
||||
|
||||
// Apply mocks base method.
|
||||
func (m *MockResourceInterface) Apply(arg0 context.Context, arg1 string, arg2 *unstructured.Unstructured, arg3 v1.ApplyOptions, arg4 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Apply(ctx context.Context, name string, obj *unstructured.Unstructured, options v1.ApplyOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2, arg3}
|
||||
for _, a := range arg4 {
|
||||
varargs := []any{ctx, name, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Apply", varargs...)
|
||||
@@ -57,32 +58,32 @@ func (m *MockResourceInterface) Apply(arg0 context.Context, arg1 string, arg2 *u
|
||||
}
|
||||
|
||||
// Apply indicates an expected call of Apply.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Apply(arg0, arg1, arg2, arg3 any, arg4 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Apply(ctx, name, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2, arg3}, arg4...)
|
||||
varargs := append([]any{ctx, name, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Apply", reflect.TypeOf((*MockResourceInterface)(nil).Apply), varargs...)
|
||||
}
|
||||
|
||||
// ApplyStatus mocks base method.
|
||||
func (m *MockResourceInterface) ApplyStatus(arg0 context.Context, arg1 string, arg2 *unstructured.Unstructured, arg3 v1.ApplyOptions) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) ApplyStatus(ctx context.Context, name string, obj *unstructured.Unstructured, options v1.ApplyOptions) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ApplyStatus", arg0, arg1, arg2, arg3)
|
||||
ret := m.ctrl.Call(m, "ApplyStatus", ctx, name, obj, options)
|
||||
ret0, _ := ret[0].(*unstructured.Unstructured)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ApplyStatus indicates an expected call of ApplyStatus.
|
||||
func (mr *MockResourceInterfaceMockRecorder) ApplyStatus(arg0, arg1, arg2, arg3 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) ApplyStatus(ctx, name, obj, options any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApplyStatus", reflect.TypeOf((*MockResourceInterface)(nil).ApplyStatus), arg0, arg1, arg2, arg3)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApplyStatus", reflect.TypeOf((*MockResourceInterface)(nil).ApplyStatus), ctx, name, obj, options)
|
||||
}
|
||||
|
||||
// Create mocks base method.
|
||||
func (m *MockResourceInterface) Create(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.CreateOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Create(ctx context.Context, obj *unstructured.Unstructured, options v1.CreateOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Create", varargs...)
|
||||
@@ -92,17 +93,17 @@ func (m *MockResourceInterface) Create(arg0 context.Context, arg1 *unstructured.
|
||||
}
|
||||
|
||||
// Create indicates an expected call of Create.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Create(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Create(ctx, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Create", reflect.TypeOf((*MockResourceInterface)(nil).Create), varargs...)
|
||||
}
|
||||
|
||||
// Delete mocks base method.
|
||||
func (m *MockResourceInterface) Delete(arg0 context.Context, arg1 string, arg2 v1.DeleteOptions, arg3 ...string) error {
|
||||
func (m *MockResourceInterface) Delete(ctx context.Context, name string, options v1.DeleteOptions, subresources ...string) error {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, name, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Delete", varargs...)
|
||||
@@ -111,31 +112,31 @@ func (m *MockResourceInterface) Delete(arg0 context.Context, arg1 string, arg2 v
|
||||
}
|
||||
|
||||
// Delete indicates an expected call of Delete.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Delete(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Delete(ctx, name, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, name, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockResourceInterface)(nil).Delete), varargs...)
|
||||
}
|
||||
|
||||
// DeleteCollection mocks base method.
|
||||
func (m *MockResourceInterface) DeleteCollection(arg0 context.Context, arg1 v1.DeleteOptions, arg2 v1.ListOptions) error {
|
||||
func (m *MockResourceInterface) DeleteCollection(ctx context.Context, options v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "DeleteCollection", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "DeleteCollection", ctx, options, listOptions)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// DeleteCollection indicates an expected call of DeleteCollection.
|
||||
func (mr *MockResourceInterfaceMockRecorder) DeleteCollection(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) DeleteCollection(ctx, options, listOptions any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteCollection", reflect.TypeOf((*MockResourceInterface)(nil).DeleteCollection), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteCollection", reflect.TypeOf((*MockResourceInterface)(nil).DeleteCollection), ctx, options, listOptions)
|
||||
}
|
||||
|
||||
// Get mocks base method.
|
||||
func (m *MockResourceInterface) Get(arg0 context.Context, arg1 string, arg2 v1.GetOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Get(ctx context.Context, name string, options v1.GetOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, name, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Get", varargs...)
|
||||
@@ -145,32 +146,32 @@ func (m *MockResourceInterface) Get(arg0 context.Context, arg1 string, arg2 v1.G
|
||||
}
|
||||
|
||||
// Get indicates an expected call of Get.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Get(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Get(ctx, name, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, name, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockResourceInterface)(nil).Get), varargs...)
|
||||
}
|
||||
|
||||
// List mocks base method.
|
||||
func (m *MockResourceInterface) List(arg0 context.Context, arg1 v1.ListOptions) (*unstructured.UnstructuredList, error) {
|
||||
func (m *MockResourceInterface) List(ctx context.Context, opts v1.ListOptions) (*unstructured.UnstructuredList, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "List", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "List", ctx, opts)
|
||||
ret0, _ := ret[0].(*unstructured.UnstructuredList)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// List indicates an expected call of List.
|
||||
func (mr *MockResourceInterfaceMockRecorder) List(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) List(ctx, opts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockResourceInterface)(nil).List), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockResourceInterface)(nil).List), ctx, opts)
|
||||
}
|
||||
|
||||
// Patch mocks base method.
|
||||
func (m *MockResourceInterface) Patch(arg0 context.Context, arg1 string, arg2 types.PatchType, arg3 []byte, arg4 v1.PatchOptions, arg5 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, options v1.PatchOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2, arg3, arg4}
|
||||
for _, a := range arg5 {
|
||||
varargs := []any{ctx, name, pt, data, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Patch", varargs...)
|
||||
@@ -180,17 +181,17 @@ func (m *MockResourceInterface) Patch(arg0 context.Context, arg1 string, arg2 ty
|
||||
}
|
||||
|
||||
// Patch indicates an expected call of Patch.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Patch(arg0, arg1, arg2, arg3, arg4 any, arg5 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Patch(ctx, name, pt, data, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2, arg3, arg4}, arg5...)
|
||||
varargs := append([]any{ctx, name, pt, data, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Patch", reflect.TypeOf((*MockResourceInterface)(nil).Patch), varargs...)
|
||||
}
|
||||
|
||||
// Update mocks base method.
|
||||
func (m *MockResourceInterface) Update(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.UpdateOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Update(ctx context.Context, obj *unstructured.Unstructured, options v1.UpdateOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Update", varargs...)
|
||||
@@ -200,38 +201,38 @@ func (m *MockResourceInterface) Update(arg0 context.Context, arg1 *unstructured.
|
||||
}
|
||||
|
||||
// Update indicates an expected call of Update.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Update(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Update(ctx, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockResourceInterface)(nil).Update), varargs...)
|
||||
}
|
||||
|
||||
// UpdateStatus mocks base method.
|
||||
func (m *MockResourceInterface) UpdateStatus(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.UpdateOptions) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) UpdateStatus(ctx context.Context, obj *unstructured.Unstructured, options v1.UpdateOptions) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "UpdateStatus", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "UpdateStatus", ctx, obj, options)
|
||||
ret0, _ := ret[0].(*unstructured.Unstructured)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// UpdateStatus indicates an expected call of UpdateStatus.
|
||||
func (mr *MockResourceInterfaceMockRecorder) UpdateStatus(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) UpdateStatus(ctx, obj, options any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateStatus", reflect.TypeOf((*MockResourceInterface)(nil).UpdateStatus), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateStatus", reflect.TypeOf((*MockResourceInterface)(nil).UpdateStatus), ctx, obj, options)
|
||||
}
|
||||
|
||||
// Watch mocks base method.
|
||||
func (m *MockResourceInterface) Watch(arg0 context.Context, arg1 v1.ListOptions) (watch.Interface, error) {
|
||||
func (m *MockResourceInterface) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Watch", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "Watch", ctx, opts)
|
||||
ret0, _ := ret[0].(watch.Interface)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// Watch indicates an expected call of Watch.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Watch(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Watch(ctx, opts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockResourceInterface)(nil).Watch), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockResourceInterface)(nil).Watch), ctx, opts)
|
||||
}
|
||||
|
@@ -23,6 +23,7 @@ import (
|
||||
type MockClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockClientMockRecorder is the mock recorder for MockClient.
|
||||
@@ -43,53 +44,53 @@ func (m *MockClient) EXPECT() *MockClientMockRecorder {
|
||||
}
|
||||
|
||||
// CloseStmt mocks base method.
|
||||
func (m *MockClient) CloseStmt(arg0 db.Closable) error {
|
||||
func (m *MockClient) CloseStmt(closable db.Closable) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "CloseStmt", arg0)
|
||||
ret := m.ctrl.Call(m, "CloseStmt", closable)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// CloseStmt indicates an expected call of CloseStmt.
|
||||
func (mr *MockClientMockRecorder) CloseStmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) CloseStmt(closable any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), closable)
|
||||
}
|
||||
|
||||
// NewConnection mocks base method.
|
||||
func (m *MockClient) NewConnection(arg0 bool) (string, error) {
|
||||
func (m *MockClient) NewConnection(isTemp bool) (string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "NewConnection", arg0)
|
||||
ret := m.ctrl.Call(m, "NewConnection", isTemp)
|
||||
ret0, _ := ret[0].(string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// NewConnection indicates an expected call of NewConnection.
|
||||
func (mr *MockClientMockRecorder) NewConnection(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) NewConnection(isTemp any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), isTemp)
|
||||
}
|
||||
|
||||
// Prepare mocks base method.
|
||||
func (m *MockClient) Prepare(arg0 string) *sql.Stmt {
|
||||
func (m *MockClient) Prepare(stmt string) *sql.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Prepare", arg0)
|
||||
ret := m.ctrl.Call(m, "Prepare", stmt)
|
||||
ret0, _ := ret[0].(*sql.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Prepare indicates an expected call of Prepare.
|
||||
func (mr *MockClientMockRecorder) Prepare(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Prepare(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), stmt)
|
||||
}
|
||||
|
||||
// QueryForRows mocks base method.
|
||||
func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, arg2 ...any) (*sql.Rows, error) {
|
||||
func (m *MockClient) QueryForRows(ctx context.Context, stmt transaction.Stmt, params ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1}
|
||||
for _, a := range arg2 {
|
||||
varargs := []any{ctx, stmt}
|
||||
for _, a := range params {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryForRows", varargs...)
|
||||
@@ -99,81 +100,81 @@ func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, a
|
||||
}
|
||||
|
||||
// QueryForRows indicates an expected call of QueryForRows.
|
||||
func (mr *MockClientMockRecorder) QueryForRows(arg0, arg1 any, arg2 ...any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) QueryForRows(ctx, stmt any, params ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1}, arg2...)
|
||||
varargs := append([]any{ctx, stmt}, params...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryForRows", reflect.TypeOf((*MockClient)(nil).QueryForRows), varargs...)
|
||||
}
|
||||
|
||||
// ReadInt mocks base method.
|
||||
func (m *MockClient) ReadInt(arg0 db.Rows) (int, error) {
|
||||
func (m *MockClient) ReadInt(rows db.Rows) (int, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadInt", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadInt", rows)
|
||||
ret0, _ := ret[0].(int)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadInt indicates an expected call of ReadInt.
|
||||
func (mr *MockClientMockRecorder) ReadInt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadInt(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), rows)
|
||||
}
|
||||
|
||||
// ReadObjects mocks base method.
|
||||
func (m *MockClient) ReadObjects(arg0 db.Rows, arg1 reflect.Type, arg2 bool) ([]any, error) {
|
||||
func (m *MockClient) ReadObjects(rows db.Rows, typ reflect.Type, shouldDecrypt bool) ([]any, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadObjects", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "ReadObjects", rows, typ, shouldDecrypt)
|
||||
ret0, _ := ret[0].([]any)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadObjects indicates an expected call of ReadObjects.
|
||||
func (mr *MockClientMockRecorder) ReadObjects(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadObjects(rows, typ, shouldDecrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), rows, typ, shouldDecrypt)
|
||||
}
|
||||
|
||||
// ReadStrings mocks base method.
|
||||
func (m *MockClient) ReadStrings(arg0 db.Rows) ([]string, error) {
|
||||
func (m *MockClient) ReadStrings(rows db.Rows) ([]string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadStrings", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadStrings", rows)
|
||||
ret0, _ := ret[0].([]string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadStrings indicates an expected call of ReadStrings.
|
||||
func (mr *MockClientMockRecorder) ReadStrings(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadStrings(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), rows)
|
||||
}
|
||||
|
||||
// Upsert mocks base method.
|
||||
func (m *MockClient) Upsert(arg0 transaction.Client, arg1 *sql.Stmt, arg2 string, arg3 any, arg4 bool) error {
|
||||
func (m *MockClient) Upsert(tx transaction.Client, stmt *sql.Stmt, key string, obj any, shouldEncrypt bool) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Upsert", arg0, arg1, arg2, arg3, arg4)
|
||||
ret := m.ctrl.Call(m, "Upsert", tx, stmt, key, obj, shouldEncrypt)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Upsert indicates an expected call of Upsert.
|
||||
func (mr *MockClientMockRecorder) Upsert(arg0, arg1, arg2, arg3, arg4 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Upsert(tx, stmt, key, obj, shouldEncrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), arg0, arg1, arg2, arg3, arg4)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), tx, stmt, key, obj, shouldEncrypt)
|
||||
}
|
||||
|
||||
// WithTransaction mocks base method.
|
||||
func (m *MockClient) WithTransaction(arg0 context.Context, arg1 bool, arg2 db.WithTransactionFunction) error {
|
||||
func (m *MockClient) WithTransaction(ctx context.Context, forWriting bool, f db.WithTransactionFunction) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "WithTransaction", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "WithTransaction", ctx, forWriting, f)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// WithTransaction indicates an expected call of WithTransaction.
|
||||
func (mr *MockClientMockRecorder) WithTransaction(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) WithTransaction(ctx, forWriting, f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), ctx, forWriting, f)
|
||||
}
|
||||
|
@@ -24,6 +24,7 @@ import (
|
||||
type MockResourceInterface struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockResourceInterfaceMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockResourceInterfaceMockRecorder is the mock recorder for MockResourceInterface.
|
||||
@@ -44,10 +45,10 @@ func (m *MockResourceInterface) EXPECT() *MockResourceInterfaceMockRecorder {
|
||||
}
|
||||
|
||||
// Apply mocks base method.
|
||||
func (m *MockResourceInterface) Apply(arg0 context.Context, arg1 string, arg2 *unstructured.Unstructured, arg3 v1.ApplyOptions, arg4 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Apply(ctx context.Context, name string, obj *unstructured.Unstructured, options v1.ApplyOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2, arg3}
|
||||
for _, a := range arg4 {
|
||||
varargs := []any{ctx, name, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Apply", varargs...)
|
||||
@@ -57,32 +58,32 @@ func (m *MockResourceInterface) Apply(arg0 context.Context, arg1 string, arg2 *u
|
||||
}
|
||||
|
||||
// Apply indicates an expected call of Apply.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Apply(arg0, arg1, arg2, arg3 any, arg4 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Apply(ctx, name, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2, arg3}, arg4...)
|
||||
varargs := append([]any{ctx, name, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Apply", reflect.TypeOf((*MockResourceInterface)(nil).Apply), varargs...)
|
||||
}
|
||||
|
||||
// ApplyStatus mocks base method.
|
||||
func (m *MockResourceInterface) ApplyStatus(arg0 context.Context, arg1 string, arg2 *unstructured.Unstructured, arg3 v1.ApplyOptions) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) ApplyStatus(ctx context.Context, name string, obj *unstructured.Unstructured, options v1.ApplyOptions) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ApplyStatus", arg0, arg1, arg2, arg3)
|
||||
ret := m.ctrl.Call(m, "ApplyStatus", ctx, name, obj, options)
|
||||
ret0, _ := ret[0].(*unstructured.Unstructured)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ApplyStatus indicates an expected call of ApplyStatus.
|
||||
func (mr *MockResourceInterfaceMockRecorder) ApplyStatus(arg0, arg1, arg2, arg3 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) ApplyStatus(ctx, name, obj, options any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApplyStatus", reflect.TypeOf((*MockResourceInterface)(nil).ApplyStatus), arg0, arg1, arg2, arg3)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ApplyStatus", reflect.TypeOf((*MockResourceInterface)(nil).ApplyStatus), ctx, name, obj, options)
|
||||
}
|
||||
|
||||
// Create mocks base method.
|
||||
func (m *MockResourceInterface) Create(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.CreateOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Create(ctx context.Context, obj *unstructured.Unstructured, options v1.CreateOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Create", varargs...)
|
||||
@@ -92,17 +93,17 @@ func (m *MockResourceInterface) Create(arg0 context.Context, arg1 *unstructured.
|
||||
}
|
||||
|
||||
// Create indicates an expected call of Create.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Create(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Create(ctx, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Create", reflect.TypeOf((*MockResourceInterface)(nil).Create), varargs...)
|
||||
}
|
||||
|
||||
// Delete mocks base method.
|
||||
func (m *MockResourceInterface) Delete(arg0 context.Context, arg1 string, arg2 v1.DeleteOptions, arg3 ...string) error {
|
||||
func (m *MockResourceInterface) Delete(ctx context.Context, name string, options v1.DeleteOptions, subresources ...string) error {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, name, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Delete", varargs...)
|
||||
@@ -111,31 +112,31 @@ func (m *MockResourceInterface) Delete(arg0 context.Context, arg1 string, arg2 v
|
||||
}
|
||||
|
||||
// Delete indicates an expected call of Delete.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Delete(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Delete(ctx, name, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, name, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockResourceInterface)(nil).Delete), varargs...)
|
||||
}
|
||||
|
||||
// DeleteCollection mocks base method.
|
||||
func (m *MockResourceInterface) DeleteCollection(arg0 context.Context, arg1 v1.DeleteOptions, arg2 v1.ListOptions) error {
|
||||
func (m *MockResourceInterface) DeleteCollection(ctx context.Context, options v1.DeleteOptions, listOptions v1.ListOptions) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "DeleteCollection", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "DeleteCollection", ctx, options, listOptions)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// DeleteCollection indicates an expected call of DeleteCollection.
|
||||
func (mr *MockResourceInterfaceMockRecorder) DeleteCollection(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) DeleteCollection(ctx, options, listOptions any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteCollection", reflect.TypeOf((*MockResourceInterface)(nil).DeleteCollection), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteCollection", reflect.TypeOf((*MockResourceInterface)(nil).DeleteCollection), ctx, options, listOptions)
|
||||
}
|
||||
|
||||
// Get mocks base method.
|
||||
func (m *MockResourceInterface) Get(arg0 context.Context, arg1 string, arg2 v1.GetOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Get(ctx context.Context, name string, options v1.GetOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, name, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Get", varargs...)
|
||||
@@ -145,32 +146,32 @@ func (m *MockResourceInterface) Get(arg0 context.Context, arg1 string, arg2 v1.G
|
||||
}
|
||||
|
||||
// Get indicates an expected call of Get.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Get(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Get(ctx, name, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, name, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockResourceInterface)(nil).Get), varargs...)
|
||||
}
|
||||
|
||||
// List mocks base method.
|
||||
func (m *MockResourceInterface) List(arg0 context.Context, arg1 v1.ListOptions) (*unstructured.UnstructuredList, error) {
|
||||
func (m *MockResourceInterface) List(ctx context.Context, opts v1.ListOptions) (*unstructured.UnstructuredList, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "List", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "List", ctx, opts)
|
||||
ret0, _ := ret[0].(*unstructured.UnstructuredList)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// List indicates an expected call of List.
|
||||
func (mr *MockResourceInterfaceMockRecorder) List(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) List(ctx, opts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockResourceInterface)(nil).List), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockResourceInterface)(nil).List), ctx, opts)
|
||||
}
|
||||
|
||||
// Patch mocks base method.
|
||||
func (m *MockResourceInterface) Patch(arg0 context.Context, arg1 string, arg2 types.PatchType, arg3 []byte, arg4 v1.PatchOptions, arg5 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, options v1.PatchOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2, arg3, arg4}
|
||||
for _, a := range arg5 {
|
||||
varargs := []any{ctx, name, pt, data, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Patch", varargs...)
|
||||
@@ -180,17 +181,17 @@ func (m *MockResourceInterface) Patch(arg0 context.Context, arg1 string, arg2 ty
|
||||
}
|
||||
|
||||
// Patch indicates an expected call of Patch.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Patch(arg0, arg1, arg2, arg3, arg4 any, arg5 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Patch(ctx, name, pt, data, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2, arg3, arg4}, arg5...)
|
||||
varargs := append([]any{ctx, name, pt, data, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Patch", reflect.TypeOf((*MockResourceInterface)(nil).Patch), varargs...)
|
||||
}
|
||||
|
||||
// Update mocks base method.
|
||||
func (m *MockResourceInterface) Update(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.UpdateOptions, arg3 ...string) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) Update(ctx context.Context, obj *unstructured.Unstructured, options v1.UpdateOptions, subresources ...string) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1, arg2}
|
||||
for _, a := range arg3 {
|
||||
varargs := []any{ctx, obj, options}
|
||||
for _, a := range subresources {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Update", varargs...)
|
||||
@@ -200,38 +201,38 @@ func (m *MockResourceInterface) Update(arg0 context.Context, arg1 *unstructured.
|
||||
}
|
||||
|
||||
// Update indicates an expected call of Update.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Update(arg0, arg1, arg2 any, arg3 ...any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Update(ctx, obj, options any, subresources ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1, arg2}, arg3...)
|
||||
varargs := append([]any{ctx, obj, options}, subresources...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockResourceInterface)(nil).Update), varargs...)
|
||||
}
|
||||
|
||||
// UpdateStatus mocks base method.
|
||||
func (m *MockResourceInterface) UpdateStatus(arg0 context.Context, arg1 *unstructured.Unstructured, arg2 v1.UpdateOptions) (*unstructured.Unstructured, error) {
|
||||
func (m *MockResourceInterface) UpdateStatus(ctx context.Context, obj *unstructured.Unstructured, options v1.UpdateOptions) (*unstructured.Unstructured, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "UpdateStatus", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "UpdateStatus", ctx, obj, options)
|
||||
ret0, _ := ret[0].(*unstructured.Unstructured)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// UpdateStatus indicates an expected call of UpdateStatus.
|
||||
func (mr *MockResourceInterfaceMockRecorder) UpdateStatus(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) UpdateStatus(ctx, obj, options any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateStatus", reflect.TypeOf((*MockResourceInterface)(nil).UpdateStatus), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateStatus", reflect.TypeOf((*MockResourceInterface)(nil).UpdateStatus), ctx, obj, options)
|
||||
}
|
||||
|
||||
// Watch mocks base method.
|
||||
func (m *MockResourceInterface) Watch(arg0 context.Context, arg1 v1.ListOptions) (watch.Interface, error) {
|
||||
func (m *MockResourceInterface) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Watch", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "Watch", ctx, opts)
|
||||
ret0, _ := ret[0].(watch.Interface)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// Watch indicates an expected call of Watch.
|
||||
func (mr *MockResourceInterfaceMockRecorder) Watch(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockResourceInterfaceMockRecorder) Watch(ctx, opts any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockResourceInterface)(nil).Watch), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockResourceInterface)(nil).Watch), ctx, opts)
|
||||
}
|
||||
|
@@ -155,7 +155,7 @@ func (f *CacheFactory) CacheFor(ctx context.Context, fields [][]string, transfor
|
||||
// expected, continue without logging
|
||||
return
|
||||
}
|
||||
cache.DefaultWatchErrorHandler(r, err)
|
||||
cache.DefaultWatchErrorHandler(ctx, r, err)
|
||||
})
|
||||
if err != nil {
|
||||
return Cache{}, err
|
||||
|
@@ -16,10 +16,10 @@ import (
|
||||
"k8s.io/client-go/tools/cache"
|
||||
)
|
||||
|
||||
//go:generate mockgen --build_flags=--mod=mod -package factory -destination ./db_mocks_test.go github.com/rancher/steve/pkg/sqlcache/db Client
|
||||
//go:generate mockgen --build_flags=--mod=mod -package factory -destination ./transaction_mocks_tests.go -mock_names Client=MockTXClient github.com/rancher/steve/pkg/sqlcache/db/transaction Client
|
||||
//go:generate mockgen --build_flags=--mod=mod -package factory -destination ./dynamic_mocks_test.go k8s.io/client-go/dynamic ResourceInterface
|
||||
//go:generate mockgen --build_flags=--mod=mod -package factory -destination ./k8s_cache_mocks_test.go k8s.io/client-go/tools/cache SharedIndexInformer
|
||||
//go:generate go run go.uber.org/mock/mockgen@latest --build_flags=--mod=mod -package factory -destination ./db_mocks_test.go github.com/rancher/steve/pkg/sqlcache/db Client
|
||||
//go:generate go run go.uber.org/mock/mockgen@latest --build_flags=--mod=mod -package factory -destination ./transaction_mocks_tests.go -mock_names Client=MockTXClient github.com/rancher/steve/pkg/sqlcache/db/transaction Client
|
||||
//go:generate go run go.uber.org/mock/mockgen@latest --build_flags=--mod=mod -package factory -destination ./dynamic_mocks_test.go k8s.io/client-go/dynamic ResourceInterface
|
||||
//go:generate go run go.uber.org/mock/mockgen@latest --build_flags=--mod=mod -package factory -destination ./k8s_cache_mocks_test.go k8s.io/client-go/tools/cache SharedIndexInformer
|
||||
|
||||
func TestNewCacheFactory(t *testing.T) {
|
||||
type testCase struct {
|
||||
@@ -485,4 +485,4 @@ func TestCacheFor(t *testing.T) {
|
||||
for _, test := range tests {
|
||||
t.Run(test.description, func(t *testing.T) { test.test(t) })
|
||||
}
|
||||
}
|
||||
}
|
@@ -10,6 +10,7 @@
|
||||
package factory
|
||||
|
||||
import (
|
||||
context "context"
|
||||
reflect "reflect"
|
||||
time "time"
|
||||
|
||||
@@ -21,6 +22,7 @@ import (
|
||||
type MockSharedIndexInformer struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockSharedIndexInformerMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockSharedIndexInformerMockRecorder is the mock recorder for MockSharedIndexInformer.
|
||||
@@ -41,47 +43,62 @@ func (m *MockSharedIndexInformer) EXPECT() *MockSharedIndexInformerMockRecorder
|
||||
}
|
||||
|
||||
// AddEventHandler mocks base method.
|
||||
func (m *MockSharedIndexInformer) AddEventHandler(arg0 cache.ResourceEventHandler) (cache.ResourceEventHandlerRegistration, error) {
|
||||
func (m *MockSharedIndexInformer) AddEventHandler(handler cache.ResourceEventHandler) (cache.ResourceEventHandlerRegistration, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "AddEventHandler", arg0)
|
||||
ret := m.ctrl.Call(m, "AddEventHandler", handler)
|
||||
ret0, _ := ret[0].(cache.ResourceEventHandlerRegistration)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// AddEventHandler indicates an expected call of AddEventHandler.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddEventHandler(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddEventHandler(handler any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddEventHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddEventHandler), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddEventHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddEventHandler), handler)
|
||||
}
|
||||
|
||||
// AddEventHandlerWithOptions mocks base method.
|
||||
func (m *MockSharedIndexInformer) AddEventHandlerWithOptions(handler cache.ResourceEventHandler, options cache.HandlerOptions) (cache.ResourceEventHandlerRegistration, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "AddEventHandlerWithOptions", handler, options)
|
||||
ret0, _ := ret[0].(cache.ResourceEventHandlerRegistration)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// AddEventHandlerWithOptions indicates an expected call of AddEventHandlerWithOptions.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddEventHandlerWithOptions(handler, options any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddEventHandlerWithOptions", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddEventHandlerWithOptions), handler, options)
|
||||
}
|
||||
|
||||
// AddEventHandlerWithResyncPeriod mocks base method.
|
||||
func (m *MockSharedIndexInformer) AddEventHandlerWithResyncPeriod(arg0 cache.ResourceEventHandler, arg1 time.Duration) (cache.ResourceEventHandlerRegistration, error) {
|
||||
func (m *MockSharedIndexInformer) AddEventHandlerWithResyncPeriod(handler cache.ResourceEventHandler, resyncPeriod time.Duration) (cache.ResourceEventHandlerRegistration, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "AddEventHandlerWithResyncPeriod", arg0, arg1)
|
||||
ret := m.ctrl.Call(m, "AddEventHandlerWithResyncPeriod", handler, resyncPeriod)
|
||||
ret0, _ := ret[0].(cache.ResourceEventHandlerRegistration)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// AddEventHandlerWithResyncPeriod indicates an expected call of AddEventHandlerWithResyncPeriod.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddEventHandlerWithResyncPeriod(arg0, arg1 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddEventHandlerWithResyncPeriod(handler, resyncPeriod any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddEventHandlerWithResyncPeriod", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddEventHandlerWithResyncPeriod), arg0, arg1)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddEventHandlerWithResyncPeriod", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddEventHandlerWithResyncPeriod), handler, resyncPeriod)
|
||||
}
|
||||
|
||||
// AddIndexers mocks base method.
|
||||
func (m *MockSharedIndexInformer) AddIndexers(arg0 cache.Indexers) error {
|
||||
func (m *MockSharedIndexInformer) AddIndexers(indexers cache.Indexers) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "AddIndexers", arg0)
|
||||
ret := m.ctrl.Call(m, "AddIndexers", indexers)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// AddIndexers indicates an expected call of AddIndexers.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddIndexers(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) AddIndexers(indexers any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddIndexers", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddIndexers), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "AddIndexers", reflect.TypeOf((*MockSharedIndexInformer)(nil).AddIndexers), indexers)
|
||||
}
|
||||
|
||||
// GetController mocks base method.
|
||||
@@ -169,55 +186,81 @@ func (mr *MockSharedIndexInformerMockRecorder) LastSyncResourceVersion() *gomock
|
||||
}
|
||||
|
||||
// RemoveEventHandler mocks base method.
|
||||
func (m *MockSharedIndexInformer) RemoveEventHandler(arg0 cache.ResourceEventHandlerRegistration) error {
|
||||
func (m *MockSharedIndexInformer) RemoveEventHandler(handle cache.ResourceEventHandlerRegistration) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "RemoveEventHandler", arg0)
|
||||
ret := m.ctrl.Call(m, "RemoveEventHandler", handle)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// RemoveEventHandler indicates an expected call of RemoveEventHandler.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) RemoveEventHandler(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) RemoveEventHandler(handle any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RemoveEventHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).RemoveEventHandler), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RemoveEventHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).RemoveEventHandler), handle)
|
||||
}
|
||||
|
||||
// Run mocks base method.
|
||||
func (m *MockSharedIndexInformer) Run(arg0 <-chan struct{}) {
|
||||
func (m *MockSharedIndexInformer) Run(stopCh <-chan struct{}) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "Run", arg0)
|
||||
m.ctrl.Call(m, "Run", stopCh)
|
||||
}
|
||||
|
||||
// Run indicates an expected call of Run.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) Run(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) Run(stopCh any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Run", reflect.TypeOf((*MockSharedIndexInformer)(nil).Run), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Run", reflect.TypeOf((*MockSharedIndexInformer)(nil).Run), stopCh)
|
||||
}
|
||||
|
||||
// RunWithContext mocks base method.
|
||||
func (m *MockSharedIndexInformer) RunWithContext(ctx context.Context) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "RunWithContext", ctx)
|
||||
}
|
||||
|
||||
// RunWithContext indicates an expected call of RunWithContext.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) RunWithContext(ctx any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RunWithContext", reflect.TypeOf((*MockSharedIndexInformer)(nil).RunWithContext), ctx)
|
||||
}
|
||||
|
||||
// SetTransform mocks base method.
|
||||
func (m *MockSharedIndexInformer) SetTransform(arg0 cache.TransformFunc) error {
|
||||
func (m *MockSharedIndexInformer) SetTransform(handler cache.TransformFunc) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "SetTransform", arg0)
|
||||
ret := m.ctrl.Call(m, "SetTransform", handler)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// SetTransform indicates an expected call of SetTransform.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) SetTransform(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) SetTransform(handler any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetTransform", reflect.TypeOf((*MockSharedIndexInformer)(nil).SetTransform), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetTransform", reflect.TypeOf((*MockSharedIndexInformer)(nil).SetTransform), handler)
|
||||
}
|
||||
|
||||
// SetWatchErrorHandler mocks base method.
|
||||
func (m *MockSharedIndexInformer) SetWatchErrorHandler(arg0 cache.WatchErrorHandler) error {
|
||||
func (m *MockSharedIndexInformer) SetWatchErrorHandler(handler cache.WatchErrorHandler) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "SetWatchErrorHandler", arg0)
|
||||
ret := m.ctrl.Call(m, "SetWatchErrorHandler", handler)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// SetWatchErrorHandler indicates an expected call of SetWatchErrorHandler.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) SetWatchErrorHandler(arg0 any) *gomock.Call {
|
||||
func (mr *MockSharedIndexInformerMockRecorder) SetWatchErrorHandler(handler any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetWatchErrorHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).SetWatchErrorHandler), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetWatchErrorHandler", reflect.TypeOf((*MockSharedIndexInformer)(nil).SetWatchErrorHandler), handler)
|
||||
}
|
||||
|
||||
// SetWatchErrorHandlerWithContext mocks base method.
|
||||
func (m *MockSharedIndexInformer) SetWatchErrorHandlerWithContext(handler cache.WatchErrorHandlerWithContext) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "SetWatchErrorHandlerWithContext", handler)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// SetWatchErrorHandlerWithContext indicates an expected call of SetWatchErrorHandlerWithContext.
|
||||
func (mr *MockSharedIndexInformerMockRecorder) SetWatchErrorHandlerWithContext(handler any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetWatchErrorHandlerWithContext", reflect.TypeOf((*MockSharedIndexInformer)(nil).SetWatchErrorHandlerWithContext), handler)
|
||||
}
|
||||
|
@@ -21,6 +21,7 @@ import (
|
||||
type MockTXClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockTXClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockTXClientMockRecorder is the mock recorder for MockTXClient.
|
||||
@@ -41,10 +42,10 @@ func (m *MockTXClient) EXPECT() *MockTXClientMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
func (m *MockTXClient) Exec(query string, args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{query}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -54,22 +55,22 @@ func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockTXClientMockRecorder) Exec(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Exec(query any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{query}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockTXClient)(nil).Exec), varargs...)
|
||||
}
|
||||
|
||||
// Stmt mocks base method.
|
||||
func (m *MockTXClient) Stmt(arg0 *sql.Stmt) transaction.Stmt {
|
||||
func (m *MockTXClient) Stmt(stmt *sql.Stmt) transaction.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Stmt", arg0)
|
||||
ret := m.ctrl.Call(m, "Stmt", stmt)
|
||||
ret0, _ := ret[0].(transaction.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Stmt indicates an expected call of Stmt.
|
||||
func (mr *MockTXClientMockRecorder) Stmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Stmt(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), stmt)
|
||||
}
|
||||
|
@@ -24,6 +24,7 @@ import (
|
||||
type MockByOptionsLister struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockByOptionsListerMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockByOptionsListerMockRecorder is the mock recorder for MockByOptionsLister.
|
||||
@@ -44,9 +45,9 @@ func (m *MockByOptionsLister) EXPECT() *MockByOptionsListerMockRecorder {
|
||||
}
|
||||
|
||||
// ListByOptions mocks base method.
|
||||
func (m *MockByOptionsLister) ListByOptions(arg0 context.Context, arg1 *sqltypes.ListOptions, arg2 []partition.Partition, arg3 string) (*unstructured.UnstructuredList, int, string, error) {
|
||||
func (m *MockByOptionsLister) ListByOptions(ctx context.Context, lo *sqltypes.ListOptions, partitions []partition.Partition, namespace string) (*unstructured.UnstructuredList, int, string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ListByOptions", arg0, arg1, arg2, arg3)
|
||||
ret := m.ctrl.Call(m, "ListByOptions", ctx, lo, partitions, namespace)
|
||||
ret0, _ := ret[0].(*unstructured.UnstructuredList)
|
||||
ret1, _ := ret[1].(int)
|
||||
ret2, _ := ret[2].(string)
|
||||
@@ -55,21 +56,21 @@ func (m *MockByOptionsLister) ListByOptions(arg0 context.Context, arg1 *sqltypes
|
||||
}
|
||||
|
||||
// ListByOptions indicates an expected call of ListByOptions.
|
||||
func (mr *MockByOptionsListerMockRecorder) ListByOptions(arg0, arg1, arg2, arg3 any) *gomock.Call {
|
||||
func (mr *MockByOptionsListerMockRecorder) ListByOptions(ctx, lo, partitions, namespace any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListByOptions", reflect.TypeOf((*MockByOptionsLister)(nil).ListByOptions), arg0, arg1, arg2, arg3)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListByOptions", reflect.TypeOf((*MockByOptionsLister)(nil).ListByOptions), ctx, lo, partitions, namespace)
|
||||
}
|
||||
|
||||
// Watch mocks base method.
|
||||
func (m *MockByOptionsLister) Watch(arg0 context.Context, arg1 WatchOptions, arg2 chan<- watch.Event) error {
|
||||
func (m *MockByOptionsLister) Watch(ctx context.Context, options WatchOptions, eventsCh chan<- watch.Event) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Watch", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "Watch", ctx, options, eventsCh)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Watch indicates an expected call of Watch.
|
||||
func (mr *MockByOptionsListerMockRecorder) Watch(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockByOptionsListerMockRecorder) Watch(ctx, options, eventsCh any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockByOptionsLister)(nil).Watch), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Watch", reflect.TypeOf((*MockByOptionsLister)(nil).Watch), ctx, options, eventsCh)
|
||||
}
|
||||
|
@@ -413,3 +413,16 @@ func (m *mockInformer) SetTransform(handler cache.TransformFunc) error {
|
||||
m.transformFunc = handler
|
||||
return m.setTranformErr
|
||||
}
|
||||
func (m *mockInformer) RunWithContext(ctx context.Context) {}
|
||||
|
||||
func (m *mockInformer) SetWatchErrorHandlerWithContext(handler cache.WatchErrorHandlerWithContext) error {
|
||||
|
||||
return nil
|
||||
|
||||
}
|
||||
|
||||
func (m *mockInformer) AddEventHandlerWithOptions(handler cache.ResourceEventHandler, options cache.HandlerOptions) (cache.ResourceEventHandlerRegistration, error) {
|
||||
|
||||
return nil, nil
|
||||
|
||||
}
|
||||
|
@@ -23,6 +23,7 @@ import (
|
||||
type MockStore struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockStoreMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockStoreMockRecorder is the mock recorder for MockStore.
|
||||
@@ -43,51 +44,51 @@ func (m *MockStore) EXPECT() *MockStoreMockRecorder {
|
||||
}
|
||||
|
||||
// Add mocks base method.
|
||||
func (m *MockStore) Add(arg0 any) error {
|
||||
func (m *MockStore) Add(obj any) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Add", arg0)
|
||||
ret := m.ctrl.Call(m, "Add", obj)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Add indicates an expected call of Add.
|
||||
func (mr *MockStoreMockRecorder) Add(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Add(obj any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Add", reflect.TypeOf((*MockStore)(nil).Add), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Add", reflect.TypeOf((*MockStore)(nil).Add), obj)
|
||||
}
|
||||
|
||||
// CloseStmt mocks base method.
|
||||
func (m *MockStore) CloseStmt(arg0 db.Closable) error {
|
||||
func (m *MockStore) CloseStmt(closable db.Closable) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "CloseStmt", arg0)
|
||||
ret := m.ctrl.Call(m, "CloseStmt", closable)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// CloseStmt indicates an expected call of CloseStmt.
|
||||
func (mr *MockStoreMockRecorder) CloseStmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) CloseStmt(closable any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockStore)(nil).CloseStmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockStore)(nil).CloseStmt), closable)
|
||||
}
|
||||
|
||||
// Delete mocks base method.
|
||||
func (m *MockStore) Delete(arg0 any) error {
|
||||
func (m *MockStore) Delete(obj any) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Delete", arg0)
|
||||
ret := m.ctrl.Call(m, "Delete", obj)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Delete indicates an expected call of Delete.
|
||||
func (mr *MockStoreMockRecorder) Delete(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Delete(obj any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockStore)(nil).Delete), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockStore)(nil).Delete), obj)
|
||||
}
|
||||
|
||||
// Get mocks base method.
|
||||
func (m *MockStore) Get(arg0 any) (any, bool, error) {
|
||||
func (m *MockStore) Get(obj any) (any, bool, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Get", arg0)
|
||||
ret := m.ctrl.Call(m, "Get", obj)
|
||||
ret0, _ := ret[0].(any)
|
||||
ret1, _ := ret[1].(bool)
|
||||
ret2, _ := ret[2].(error)
|
||||
@@ -95,15 +96,15 @@ func (m *MockStore) Get(arg0 any) (any, bool, error) {
|
||||
}
|
||||
|
||||
// Get indicates an expected call of Get.
|
||||
func (mr *MockStoreMockRecorder) Get(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Get(obj any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockStore)(nil).Get), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockStore)(nil).Get), obj)
|
||||
}
|
||||
|
||||
// GetByKey mocks base method.
|
||||
func (m *MockStore) GetByKey(arg0 string) (any, bool, error) {
|
||||
func (m *MockStore) GetByKey(key string) (any, bool, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "GetByKey", arg0)
|
||||
ret := m.ctrl.Call(m, "GetByKey", key)
|
||||
ret0, _ := ret[0].(any)
|
||||
ret1, _ := ret[1].(bool)
|
||||
ret2, _ := ret[2].(error)
|
||||
@@ -111,9 +112,9 @@ func (m *MockStore) GetByKey(arg0 string) (any, bool, error) {
|
||||
}
|
||||
|
||||
// GetByKey indicates an expected call of GetByKey.
|
||||
func (mr *MockStoreMockRecorder) GetByKey(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) GetByKey(key any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetByKey", reflect.TypeOf((*MockStore)(nil).GetByKey), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetByKey", reflect.TypeOf((*MockStore)(nil).GetByKey), key)
|
||||
}
|
||||
|
||||
// GetName mocks base method.
|
||||
@@ -187,39 +188,39 @@ func (mr *MockStoreMockRecorder) ListKeys() *gomock.Call {
|
||||
}
|
||||
|
||||
// NewConnection mocks base method.
|
||||
func (m *MockStore) NewConnection(arg0 bool) (string, error) {
|
||||
func (m *MockStore) NewConnection(isTemp bool) (string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "NewConnection", arg0)
|
||||
ret := m.ctrl.Call(m, "NewConnection", isTemp)
|
||||
ret0, _ := ret[0].(string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// NewConnection indicates an expected call of NewConnection.
|
||||
func (mr *MockStoreMockRecorder) NewConnection(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) NewConnection(isTemp any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockStore)(nil).NewConnection), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockStore)(nil).NewConnection), isTemp)
|
||||
}
|
||||
|
||||
// Prepare mocks base method.
|
||||
func (m *MockStore) Prepare(arg0 string) *sql.Stmt {
|
||||
func (m *MockStore) Prepare(stmt string) *sql.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Prepare", arg0)
|
||||
ret := m.ctrl.Call(m, "Prepare", stmt)
|
||||
ret0, _ := ret[0].(*sql.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Prepare indicates an expected call of Prepare.
|
||||
func (mr *MockStoreMockRecorder) Prepare(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Prepare(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockStore)(nil).Prepare), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockStore)(nil).Prepare), stmt)
|
||||
}
|
||||
|
||||
// QueryForRows mocks base method.
|
||||
func (m *MockStore) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, arg2 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStore) QueryForRows(ctx context.Context, stmt transaction.Stmt, params ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1}
|
||||
for _, a := range arg2 {
|
||||
varargs := []any{ctx, stmt}
|
||||
for _, a := range params {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryForRows", varargs...)
|
||||
@@ -229,103 +230,103 @@ func (m *MockStore) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, ar
|
||||
}
|
||||
|
||||
// QueryForRows indicates an expected call of QueryForRows.
|
||||
func (mr *MockStoreMockRecorder) QueryForRows(arg0, arg1 any, arg2 ...any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) QueryForRows(ctx, stmt any, params ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1}, arg2...)
|
||||
varargs := append([]any{ctx, stmt}, params...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryForRows", reflect.TypeOf((*MockStore)(nil).QueryForRows), varargs...)
|
||||
}
|
||||
|
||||
// ReadInt mocks base method.
|
||||
func (m *MockStore) ReadInt(arg0 db.Rows) (int, error) {
|
||||
func (m *MockStore) ReadInt(rows db.Rows) (int, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadInt", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadInt", rows)
|
||||
ret0, _ := ret[0].(int)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadInt indicates an expected call of ReadInt.
|
||||
func (mr *MockStoreMockRecorder) ReadInt(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) ReadInt(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockStore)(nil).ReadInt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockStore)(nil).ReadInt), rows)
|
||||
}
|
||||
|
||||
// ReadObjects mocks base method.
|
||||
func (m *MockStore) ReadObjects(arg0 db.Rows, arg1 reflect.Type, arg2 bool) ([]any, error) {
|
||||
func (m *MockStore) ReadObjects(rows db.Rows, typ reflect.Type, shouldDecrypt bool) ([]any, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadObjects", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "ReadObjects", rows, typ, shouldDecrypt)
|
||||
ret0, _ := ret[0].([]any)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadObjects indicates an expected call of ReadObjects.
|
||||
func (mr *MockStoreMockRecorder) ReadObjects(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) ReadObjects(rows, typ, shouldDecrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockStore)(nil).ReadObjects), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockStore)(nil).ReadObjects), rows, typ, shouldDecrypt)
|
||||
}
|
||||
|
||||
// ReadStrings mocks base method.
|
||||
func (m *MockStore) ReadStrings(arg0 db.Rows) ([]string, error) {
|
||||
func (m *MockStore) ReadStrings(rows db.Rows) ([]string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadStrings", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadStrings", rows)
|
||||
ret0, _ := ret[0].([]string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadStrings indicates an expected call of ReadStrings.
|
||||
func (mr *MockStoreMockRecorder) ReadStrings(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) ReadStrings(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockStore)(nil).ReadStrings), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockStore)(nil).ReadStrings), rows)
|
||||
}
|
||||
|
||||
// RegisterAfterAdd mocks base method.
|
||||
func (m *MockStore) RegisterAfterAdd(arg0 func(string, any, transaction.Client) error) {
|
||||
func (m *MockStore) RegisterAfterAdd(f func(string, any, transaction.Client) error) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "RegisterAfterAdd", arg0)
|
||||
m.ctrl.Call(m, "RegisterAfterAdd", f)
|
||||
}
|
||||
|
||||
// RegisterAfterAdd indicates an expected call of RegisterAfterAdd.
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterAdd(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterAdd(f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterAdd", reflect.TypeOf((*MockStore)(nil).RegisterAfterAdd), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterAdd", reflect.TypeOf((*MockStore)(nil).RegisterAfterAdd), f)
|
||||
}
|
||||
|
||||
// RegisterAfterDelete mocks base method.
|
||||
func (m *MockStore) RegisterAfterDelete(arg0 func(string, any, transaction.Client) error) {
|
||||
func (m *MockStore) RegisterAfterDelete(f func(string, any, transaction.Client) error) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "RegisterAfterDelete", arg0)
|
||||
m.ctrl.Call(m, "RegisterAfterDelete", f)
|
||||
}
|
||||
|
||||
// RegisterAfterDelete indicates an expected call of RegisterAfterDelete.
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterDelete(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterDelete(f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterDelete", reflect.TypeOf((*MockStore)(nil).RegisterAfterDelete), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterDelete", reflect.TypeOf((*MockStore)(nil).RegisterAfterDelete), f)
|
||||
}
|
||||
|
||||
// RegisterAfterDeleteAll mocks base method.
|
||||
func (m *MockStore) RegisterAfterDeleteAll(arg0 func(transaction.Client) error) {
|
||||
func (m *MockStore) RegisterAfterDeleteAll(f func(transaction.Client) error) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "RegisterAfterDeleteAll", arg0)
|
||||
m.ctrl.Call(m, "RegisterAfterDeleteAll", f)
|
||||
}
|
||||
|
||||
// RegisterAfterDeleteAll indicates an expected call of RegisterAfterDeleteAll.
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterDeleteAll(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterDeleteAll(f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterDeleteAll", reflect.TypeOf((*MockStore)(nil).RegisterAfterDeleteAll), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterDeleteAll", reflect.TypeOf((*MockStore)(nil).RegisterAfterDeleteAll), f)
|
||||
}
|
||||
|
||||
// RegisterAfterUpdate mocks base method.
|
||||
func (m *MockStore) RegisterAfterUpdate(arg0 func(string, any, transaction.Client) error) {
|
||||
func (m *MockStore) RegisterAfterUpdate(f func(string, any, transaction.Client) error) {
|
||||
m.ctrl.T.Helper()
|
||||
m.ctrl.Call(m, "RegisterAfterUpdate", arg0)
|
||||
m.ctrl.Call(m, "RegisterAfterUpdate", f)
|
||||
}
|
||||
|
||||
// RegisterAfterUpdate indicates an expected call of RegisterAfterUpdate.
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterUpdate(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) RegisterAfterUpdate(f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterUpdate", reflect.TypeOf((*MockStore)(nil).RegisterAfterUpdate), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "RegisterAfterUpdate", reflect.TypeOf((*MockStore)(nil).RegisterAfterUpdate), f)
|
||||
}
|
||||
|
||||
// Replace mocks base method.
|
||||
@@ -357,43 +358,43 @@ func (mr *MockStoreMockRecorder) Resync() *gomock.Call {
|
||||
}
|
||||
|
||||
// Update mocks base method.
|
||||
func (m *MockStore) Update(arg0 any) error {
|
||||
func (m *MockStore) Update(obj any) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Update", arg0)
|
||||
ret := m.ctrl.Call(m, "Update", obj)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Update indicates an expected call of Update.
|
||||
func (mr *MockStoreMockRecorder) Update(arg0 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Update(obj any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockStore)(nil).Update), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockStore)(nil).Update), obj)
|
||||
}
|
||||
|
||||
// Upsert mocks base method.
|
||||
func (m *MockStore) Upsert(arg0 transaction.Client, arg1 *sql.Stmt, arg2 string, arg3 any, arg4 bool) error {
|
||||
func (m *MockStore) Upsert(tx transaction.Client, stmt *sql.Stmt, key string, obj any, shouldEncrypt bool) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Upsert", arg0, arg1, arg2, arg3, arg4)
|
||||
ret := m.ctrl.Call(m, "Upsert", tx, stmt, key, obj, shouldEncrypt)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Upsert indicates an expected call of Upsert.
|
||||
func (mr *MockStoreMockRecorder) Upsert(arg0, arg1, arg2, arg3, arg4 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) Upsert(tx, stmt, key, obj, shouldEncrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockStore)(nil).Upsert), arg0, arg1, arg2, arg3, arg4)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockStore)(nil).Upsert), tx, stmt, key, obj, shouldEncrypt)
|
||||
}
|
||||
|
||||
// WithTransaction mocks base method.
|
||||
func (m *MockStore) WithTransaction(arg0 context.Context, arg1 bool, arg2 db.WithTransactionFunction) error {
|
||||
func (m *MockStore) WithTransaction(ctx context.Context, forWriting bool, f db.WithTransactionFunction) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "WithTransaction", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "WithTransaction", ctx, forWriting, f)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// WithTransaction indicates an expected call of WithTransaction.
|
||||
func (mr *MockStoreMockRecorder) WithTransaction(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockStoreMockRecorder) WithTransaction(ctx, forWriting, f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockStore)(nil).WithTransaction), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockStore)(nil).WithTransaction), ctx, forWriting, f)
|
||||
}
|
||||
|
@@ -22,6 +22,7 @@ import (
|
||||
type MockStmt struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockStmtMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockStmtMockRecorder is the mock recorder for MockStmt.
|
||||
@@ -42,10 +43,10 @@ func (m *MockStmt) EXPECT() *MockStmtMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
func (m *MockStmt) Exec(args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -55,16 +56,16 @@ func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockStmtMockRecorder) Exec(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Exec(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), args...)
|
||||
}
|
||||
|
||||
// Query mocks base method.
|
||||
func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) Query(args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Query", varargs...)
|
||||
@@ -74,16 +75,16 @@ func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
}
|
||||
|
||||
// Query indicates an expected call of Query.
|
||||
func (mr *MockStmtMockRecorder) Query(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Query(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), args...)
|
||||
}
|
||||
|
||||
// QueryContext mocks base method.
|
||||
func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) QueryContext(ctx context.Context, args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryContext", varargs...)
|
||||
@@ -93,17 +94,17 @@ func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, e
|
||||
}
|
||||
|
||||
// QueryContext indicates an expected call of QueryContext.
|
||||
func (mr *MockStmtMockRecorder) QueryContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryContext", reflect.TypeOf((*MockStmt)(nil).QueryContext), varargs...)
|
||||
}
|
||||
|
||||
// QueryRowContext mocks base method.
|
||||
func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
func (m *MockStmt) QueryRowContext(ctx context.Context, args ...any) *sql.Row {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryRowContext", varargs...)
|
||||
@@ -112,9 +113,9 @@ func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
}
|
||||
|
||||
// QueryRowContext indicates an expected call of QueryRowContext.
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryRowContext", reflect.TypeOf((*MockStmt)(nil).QueryRowContext), varargs...)
|
||||
}
|
||||
|
||||
@@ -122,6 +123,7 @@ func (mr *MockStmtMockRecorder) QueryRowContext(arg0 any, arg1 ...any) *gomock.C
|
||||
type MockTXClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockTXClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockTXClientMockRecorder is the mock recorder for MockTXClient.
|
||||
@@ -142,10 +144,10 @@ func (m *MockTXClient) EXPECT() *MockTXClientMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
func (m *MockTXClient) Exec(query string, args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{query}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -155,22 +157,22 @@ func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockTXClientMockRecorder) Exec(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Exec(query any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{query}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockTXClient)(nil).Exec), varargs...)
|
||||
}
|
||||
|
||||
// Stmt mocks base method.
|
||||
func (m *MockTXClient) Stmt(arg0 *sql.Stmt) transaction.Stmt {
|
||||
func (m *MockTXClient) Stmt(stmt *sql.Stmt) transaction.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Stmt", arg0)
|
||||
ret := m.ctrl.Call(m, "Stmt", stmt)
|
||||
ret0, _ := ret[0].(transaction.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Stmt indicates an expected call of Stmt.
|
||||
func (mr *MockTXClientMockRecorder) Stmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Stmt(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), stmt)
|
||||
}
|
||||
|
@@ -23,6 +23,7 @@ import (
|
||||
type MockRows struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockRowsMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockRowsMockRecorder is the mock recorder for MockRows.
|
||||
@@ -85,10 +86,10 @@ func (mr *MockRowsMockRecorder) Next() *gomock.Call {
|
||||
}
|
||||
|
||||
// Scan mocks base method.
|
||||
func (m *MockRows) Scan(arg0 ...any) error {
|
||||
func (m *MockRows) Scan(dest ...any) error {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range dest {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Scan", varargs...)
|
||||
@@ -97,15 +98,16 @@ func (m *MockRows) Scan(arg0 ...any) error {
|
||||
}
|
||||
|
||||
// Scan indicates an expected call of Scan.
|
||||
func (mr *MockRowsMockRecorder) Scan(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockRowsMockRecorder) Scan(dest ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Scan", reflect.TypeOf((*MockRows)(nil).Scan), dest...)
|
||||
}
|
||||
|
||||
// MockClient is a mock of Client interface.
|
||||
type MockClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockClientMockRecorder is the mock recorder for MockClient.
|
||||
@@ -126,53 +128,53 @@ func (m *MockClient) EXPECT() *MockClientMockRecorder {
|
||||
}
|
||||
|
||||
// CloseStmt mocks base method.
|
||||
func (m *MockClient) CloseStmt(arg0 db.Closable) error {
|
||||
func (m *MockClient) CloseStmt(closable db.Closable) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "CloseStmt", arg0)
|
||||
ret := m.ctrl.Call(m, "CloseStmt", closable)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// CloseStmt indicates an expected call of CloseStmt.
|
||||
func (mr *MockClientMockRecorder) CloseStmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) CloseStmt(closable any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseStmt", reflect.TypeOf((*MockClient)(nil).CloseStmt), closable)
|
||||
}
|
||||
|
||||
// NewConnection mocks base method.
|
||||
func (m *MockClient) NewConnection(arg0 bool) (string, error) {
|
||||
func (m *MockClient) NewConnection(isTemp bool) (string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "NewConnection", arg0)
|
||||
ret := m.ctrl.Call(m, "NewConnection", isTemp)
|
||||
ret0, _ := ret[0].(string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// NewConnection indicates an expected call of NewConnection.
|
||||
func (mr *MockClientMockRecorder) NewConnection(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) NewConnection(isTemp any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewConnection", reflect.TypeOf((*MockClient)(nil).NewConnection), isTemp)
|
||||
}
|
||||
|
||||
// Prepare mocks base method.
|
||||
func (m *MockClient) Prepare(arg0 string) *sql.Stmt {
|
||||
func (m *MockClient) Prepare(stmt string) *sql.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Prepare", arg0)
|
||||
ret := m.ctrl.Call(m, "Prepare", stmt)
|
||||
ret0, _ := ret[0].(*sql.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Prepare indicates an expected call of Prepare.
|
||||
func (mr *MockClientMockRecorder) Prepare(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Prepare(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Prepare", reflect.TypeOf((*MockClient)(nil).Prepare), stmt)
|
||||
}
|
||||
|
||||
// QueryForRows mocks base method.
|
||||
func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, arg2 ...any) (*sql.Rows, error) {
|
||||
func (m *MockClient) QueryForRows(ctx context.Context, stmt transaction.Stmt, params ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0, arg1}
|
||||
for _, a := range arg2 {
|
||||
varargs := []any{ctx, stmt}
|
||||
for _, a := range params {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryForRows", varargs...)
|
||||
@@ -182,81 +184,81 @@ func (m *MockClient) QueryForRows(arg0 context.Context, arg1 transaction.Stmt, a
|
||||
}
|
||||
|
||||
// QueryForRows indicates an expected call of QueryForRows.
|
||||
func (mr *MockClientMockRecorder) QueryForRows(arg0, arg1 any, arg2 ...any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) QueryForRows(ctx, stmt any, params ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0, arg1}, arg2...)
|
||||
varargs := append([]any{ctx, stmt}, params...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryForRows", reflect.TypeOf((*MockClient)(nil).QueryForRows), varargs...)
|
||||
}
|
||||
|
||||
// ReadInt mocks base method.
|
||||
func (m *MockClient) ReadInt(arg0 db.Rows) (int, error) {
|
||||
func (m *MockClient) ReadInt(rows db.Rows) (int, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadInt", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadInt", rows)
|
||||
ret0, _ := ret[0].(int)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadInt indicates an expected call of ReadInt.
|
||||
func (mr *MockClientMockRecorder) ReadInt(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadInt(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadInt", reflect.TypeOf((*MockClient)(nil).ReadInt), rows)
|
||||
}
|
||||
|
||||
// ReadObjects mocks base method.
|
||||
func (m *MockClient) ReadObjects(arg0 db.Rows, arg1 reflect.Type, arg2 bool) ([]any, error) {
|
||||
func (m *MockClient) ReadObjects(rows db.Rows, typ reflect.Type, shouldDecrypt bool) ([]any, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadObjects", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "ReadObjects", rows, typ, shouldDecrypt)
|
||||
ret0, _ := ret[0].([]any)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadObjects indicates an expected call of ReadObjects.
|
||||
func (mr *MockClientMockRecorder) ReadObjects(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadObjects(rows, typ, shouldDecrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadObjects", reflect.TypeOf((*MockClient)(nil).ReadObjects), rows, typ, shouldDecrypt)
|
||||
}
|
||||
|
||||
// ReadStrings mocks base method.
|
||||
func (m *MockClient) ReadStrings(arg0 db.Rows) ([]string, error) {
|
||||
func (m *MockClient) ReadStrings(rows db.Rows) ([]string, error) {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "ReadStrings", arg0)
|
||||
ret := m.ctrl.Call(m, "ReadStrings", rows)
|
||||
ret0, _ := ret[0].([]string)
|
||||
ret1, _ := ret[1].(error)
|
||||
return ret0, ret1
|
||||
}
|
||||
|
||||
// ReadStrings indicates an expected call of ReadStrings.
|
||||
func (mr *MockClientMockRecorder) ReadStrings(arg0 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) ReadStrings(rows any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ReadStrings", reflect.TypeOf((*MockClient)(nil).ReadStrings), rows)
|
||||
}
|
||||
|
||||
// Upsert mocks base method.
|
||||
func (m *MockClient) Upsert(arg0 transaction.Client, arg1 *sql.Stmt, arg2 string, arg3 any, arg4 bool) error {
|
||||
func (m *MockClient) Upsert(tx transaction.Client, stmt *sql.Stmt, key string, obj any, shouldEncrypt bool) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Upsert", arg0, arg1, arg2, arg3, arg4)
|
||||
ret := m.ctrl.Call(m, "Upsert", tx, stmt, key, obj, shouldEncrypt)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Upsert indicates an expected call of Upsert.
|
||||
func (mr *MockClientMockRecorder) Upsert(arg0, arg1, arg2, arg3, arg4 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) Upsert(tx, stmt, key, obj, shouldEncrypt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), arg0, arg1, arg2, arg3, arg4)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Upsert", reflect.TypeOf((*MockClient)(nil).Upsert), tx, stmt, key, obj, shouldEncrypt)
|
||||
}
|
||||
|
||||
// WithTransaction mocks base method.
|
||||
func (m *MockClient) WithTransaction(arg0 context.Context, arg1 bool, arg2 db.WithTransactionFunction) error {
|
||||
func (m *MockClient) WithTransaction(ctx context.Context, forWriting bool, f db.WithTransactionFunction) error {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "WithTransaction", arg0, arg1, arg2)
|
||||
ret := m.ctrl.Call(m, "WithTransaction", ctx, forWriting, f)
|
||||
ret0, _ := ret[0].(error)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// WithTransaction indicates an expected call of WithTransaction.
|
||||
func (mr *MockClientMockRecorder) WithTransaction(arg0, arg1, arg2 any) *gomock.Call {
|
||||
func (mr *MockClientMockRecorder) WithTransaction(ctx, forWriting, f any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), arg0, arg1, arg2)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "WithTransaction", reflect.TypeOf((*MockClient)(nil).WithTransaction), ctx, forWriting, f)
|
||||
}
|
||||
|
@@ -22,6 +22,7 @@ import (
|
||||
type MockStmt struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockStmtMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockStmtMockRecorder is the mock recorder for MockStmt.
|
||||
@@ -42,10 +43,10 @@ func (m *MockStmt) EXPECT() *MockStmtMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
func (m *MockStmt) Exec(args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -55,16 +56,16 @@ func (m *MockStmt) Exec(arg0 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockStmtMockRecorder) Exec(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Exec(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockStmt)(nil).Exec), args...)
|
||||
}
|
||||
|
||||
// Query mocks base method.
|
||||
func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) Query(args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{}
|
||||
for _, a := range arg0 {
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Query", varargs...)
|
||||
@@ -74,16 +75,16 @@ func (m *MockStmt) Query(arg0 ...any) (*sql.Rows, error) {
|
||||
}
|
||||
|
||||
// Query indicates an expected call of Query.
|
||||
func (mr *MockStmtMockRecorder) Query(arg0 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) Query(args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), arg0...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Query", reflect.TypeOf((*MockStmt)(nil).Query), args...)
|
||||
}
|
||||
|
||||
// QueryContext mocks base method.
|
||||
func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, error) {
|
||||
func (m *MockStmt) QueryContext(ctx context.Context, args ...any) (*sql.Rows, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryContext", varargs...)
|
||||
@@ -93,17 +94,17 @@ func (m *MockStmt) QueryContext(arg0 context.Context, arg1 ...any) (*sql.Rows, e
|
||||
}
|
||||
|
||||
// QueryContext indicates an expected call of QueryContext.
|
||||
func (mr *MockStmtMockRecorder) QueryContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryContext", reflect.TypeOf((*MockStmt)(nil).QueryContext), varargs...)
|
||||
}
|
||||
|
||||
// QueryRowContext mocks base method.
|
||||
func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
func (m *MockStmt) QueryRowContext(ctx context.Context, args ...any) *sql.Row {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{ctx}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "QueryRowContext", varargs...)
|
||||
@@ -112,9 +113,9 @@ func (m *MockStmt) QueryRowContext(arg0 context.Context, arg1 ...any) *sql.Row {
|
||||
}
|
||||
|
||||
// QueryRowContext indicates an expected call of QueryRowContext.
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockStmtMockRecorder) QueryRowContext(ctx any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{ctx}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "QueryRowContext", reflect.TypeOf((*MockStmt)(nil).QueryRowContext), varargs...)
|
||||
}
|
||||
|
||||
@@ -122,6 +123,7 @@ func (mr *MockStmtMockRecorder) QueryRowContext(arg0 any, arg1 ...any) *gomock.C
|
||||
type MockTXClient struct {
|
||||
ctrl *gomock.Controller
|
||||
recorder *MockTXClientMockRecorder
|
||||
isgomock struct{}
|
||||
}
|
||||
|
||||
// MockTXClientMockRecorder is the mock recorder for MockTXClient.
|
||||
@@ -142,10 +144,10 @@ func (m *MockTXClient) EXPECT() *MockTXClientMockRecorder {
|
||||
}
|
||||
|
||||
// Exec mocks base method.
|
||||
func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
func (m *MockTXClient) Exec(query string, args ...any) (sql.Result, error) {
|
||||
m.ctrl.T.Helper()
|
||||
varargs := []any{arg0}
|
||||
for _, a := range arg1 {
|
||||
varargs := []any{query}
|
||||
for _, a := range args {
|
||||
varargs = append(varargs, a)
|
||||
}
|
||||
ret := m.ctrl.Call(m, "Exec", varargs...)
|
||||
@@ -155,22 +157,22 @@ func (m *MockTXClient) Exec(arg0 string, arg1 ...any) (sql.Result, error) {
|
||||
}
|
||||
|
||||
// Exec indicates an expected call of Exec.
|
||||
func (mr *MockTXClientMockRecorder) Exec(arg0 any, arg1 ...any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Exec(query any, args ...any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
varargs := append([]any{arg0}, arg1...)
|
||||
varargs := append([]any{query}, args...)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Exec", reflect.TypeOf((*MockTXClient)(nil).Exec), varargs...)
|
||||
}
|
||||
|
||||
// Stmt mocks base method.
|
||||
func (m *MockTXClient) Stmt(arg0 *sql.Stmt) transaction.Stmt {
|
||||
func (m *MockTXClient) Stmt(stmt *sql.Stmt) transaction.Stmt {
|
||||
m.ctrl.T.Helper()
|
||||
ret := m.ctrl.Call(m, "Stmt", arg0)
|
||||
ret := m.ctrl.Call(m, "Stmt", stmt)
|
||||
ret0, _ := ret[0].(transaction.Stmt)
|
||||
return ret0
|
||||
}
|
||||
|
||||
// Stmt indicates an expected call of Stmt.
|
||||
func (mr *MockTXClientMockRecorder) Stmt(arg0 any) *gomock.Call {
|
||||
func (mr *MockTXClientMockRecorder) Stmt(stmt any) *gomock.Call {
|
||||
mr.mock.ctrl.T.Helper()
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), arg0)
|
||||
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stmt", reflect.TypeOf((*MockTXClient)(nil).Stmt), stmt)
|
||||
}
|
||||
|
Reference in New Issue
Block a user