chore(test): fix mockery deprecation warnings (#22998)

Signed-off-by: Michael Crenshaw <350466+crenshaw-dev@users.noreply.github.com>
This commit is contained in:
Michael Crenshaw 2025-05-15 14:06:03 -04:00 committed by GitHub
parent af3a37b053
commit f0d783b1e7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
30 changed files with 8459 additions and 77 deletions

View file

@ -3,7 +3,10 @@ filename: "{{.InterfaceName}}.go"
dir: "{{.InterfaceDir}}/mocks"
outpkg: "mocks"
mockname: "{{.InterfaceName}}"
with-expecter: false
with-expecter: true
resolve-type-alias: false
disable-version-string: true
issue-845-fix: true
# individual interface config
packages:
github.com/argoproj/argo-cd/v3/applicationset/generators:

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,24 +17,32 @@ type Generator struct {
mock.Mock
}
type Generator_Expecter struct {
mock *mock.Mock
}
func (_m *Generator) EXPECT() *Generator_Expecter {
return &Generator_Expecter{mock: &_m.Mock}
}
// GenerateParams provides a mock function with given fields: appSetGenerator, applicationSetInfo, _a2
func (_m *Generator) GenerateParams(appSetGenerator *v1alpha1.ApplicationSetGenerator, applicationSetInfo *v1alpha1.ApplicationSet, _a2 client.Client) ([]map[string]interface{}, error) {
func (_m *Generator) GenerateParams(appSetGenerator *v1alpha1.ApplicationSetGenerator, applicationSetInfo *v1alpha1.ApplicationSet, _a2 client.Client) ([]map[string]any, error) {
ret := _m.Called(appSetGenerator, applicationSetInfo, _a2)
if len(ret) == 0 {
panic("no return value specified for GenerateParams")
}
var r0 []map[string]interface{}
var r0 []map[string]any
var r1 error
if rf, ok := ret.Get(0).(func(*v1alpha1.ApplicationSetGenerator, *v1alpha1.ApplicationSet, client.Client) ([]map[string]interface{}, error)); ok {
if rf, ok := ret.Get(0).(func(*v1alpha1.ApplicationSetGenerator, *v1alpha1.ApplicationSet, client.Client) ([]map[string]any, error)); ok {
return rf(appSetGenerator, applicationSetInfo, _a2)
}
if rf, ok := ret.Get(0).(func(*v1alpha1.ApplicationSetGenerator, *v1alpha1.ApplicationSet, client.Client) []map[string]interface{}); ok {
if rf, ok := ret.Get(0).(func(*v1alpha1.ApplicationSetGenerator, *v1alpha1.ApplicationSet, client.Client) []map[string]any); ok {
r0 = rf(appSetGenerator, applicationSetInfo, _a2)
} else {
if ret.Get(0) != nil {
r0 = ret.Get(0).([]map[string]interface{})
r0 = ret.Get(0).([]map[string]any)
}
}
@ -47,6 +55,36 @@ func (_m *Generator) GenerateParams(appSetGenerator *v1alpha1.ApplicationSetGene
return r0, r1
}
// Generator_GenerateParams_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateParams'
type Generator_GenerateParams_Call struct {
*mock.Call
}
// GenerateParams is a helper method to define mock.On call
// - appSetGenerator *v1alpha1.ApplicationSetGenerator
// - applicationSetInfo *v1alpha1.ApplicationSet
// - _a2 client.Client
func (_e *Generator_Expecter) GenerateParams(appSetGenerator interface{}, applicationSetInfo interface{}, _a2 interface{}) *Generator_GenerateParams_Call {
return &Generator_GenerateParams_Call{Call: _e.mock.On("GenerateParams", appSetGenerator, applicationSetInfo, _a2)}
}
func (_c *Generator_GenerateParams_Call) Run(run func(appSetGenerator *v1alpha1.ApplicationSetGenerator, applicationSetInfo *v1alpha1.ApplicationSet, _a2 client.Client)) *Generator_GenerateParams_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.ApplicationSetGenerator), args[1].(*v1alpha1.ApplicationSet), args[2].(client.Client))
})
return _c
}
func (_c *Generator_GenerateParams_Call) Return(_a0 []map[string]any, _a1 error) *Generator_GenerateParams_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Generator_GenerateParams_Call) RunAndReturn(run func(*v1alpha1.ApplicationSetGenerator, *v1alpha1.ApplicationSet, client.Client) ([]map[string]any, error)) *Generator_GenerateParams_Call {
_c.Call.Return(run)
return _c
}
// GetRequeueAfter provides a mock function with given fields: appSetGenerator
func (_m *Generator) GetRequeueAfter(appSetGenerator *v1alpha1.ApplicationSetGenerator) time.Duration {
ret := _m.Called(appSetGenerator)
@ -65,6 +103,34 @@ func (_m *Generator) GetRequeueAfter(appSetGenerator *v1alpha1.ApplicationSetGen
return r0
}
// Generator_GetRequeueAfter_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRequeueAfter'
type Generator_GetRequeueAfter_Call struct {
*mock.Call
}
// GetRequeueAfter is a helper method to define mock.On call
// - appSetGenerator *v1alpha1.ApplicationSetGenerator
func (_e *Generator_Expecter) GetRequeueAfter(appSetGenerator interface{}) *Generator_GetRequeueAfter_Call {
return &Generator_GetRequeueAfter_Call{Call: _e.mock.On("GetRequeueAfter", appSetGenerator)}
}
func (_c *Generator_GetRequeueAfter_Call) Run(run func(appSetGenerator *v1alpha1.ApplicationSetGenerator)) *Generator_GetRequeueAfter_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.ApplicationSetGenerator))
})
return _c
}
func (_c *Generator_GetRequeueAfter_Call) Return(_a0 time.Duration) *Generator_GetRequeueAfter_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Generator_GetRequeueAfter_Call) RunAndReturn(run func(*v1alpha1.ApplicationSetGenerator) time.Duration) *Generator_GetRequeueAfter_Call {
_c.Call.Return(run)
return _c
}
// GetTemplate provides a mock function with given fields: appSetGenerator
func (_m *Generator) GetTemplate(appSetGenerator *v1alpha1.ApplicationSetGenerator) *v1alpha1.ApplicationSetTemplate {
ret := _m.Called(appSetGenerator)
@ -85,6 +151,34 @@ func (_m *Generator) GetTemplate(appSetGenerator *v1alpha1.ApplicationSetGenerat
return r0
}
// Generator_GetTemplate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTemplate'
type Generator_GetTemplate_Call struct {
*mock.Call
}
// GetTemplate is a helper method to define mock.On call
// - appSetGenerator *v1alpha1.ApplicationSetGenerator
func (_e *Generator_Expecter) GetTemplate(appSetGenerator interface{}) *Generator_GetTemplate_Call {
return &Generator_GetTemplate_Call{Call: _e.mock.On("GetTemplate", appSetGenerator)}
}
func (_c *Generator_GetTemplate_Call) Run(run func(appSetGenerator *v1alpha1.ApplicationSetGenerator)) *Generator_GetTemplate_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.ApplicationSetGenerator))
})
return _c
}
func (_c *Generator_GetTemplate_Call) Return(_a0 *v1alpha1.ApplicationSetTemplate) *Generator_GetTemplate_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Generator_GetTemplate_Call) RunAndReturn(run func(*v1alpha1.ApplicationSetGenerator) *v1alpha1.ApplicationSetTemplate) *Generator_GetTemplate_Call {
_c.Call.Return(run)
return _c
}
// NewGenerator creates a new instance of Generator. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewGenerator(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -13,6 +13,14 @@ type Repos struct {
mock.Mock
}
type Repos_Expecter struct {
mock *mock.Mock
}
func (_m *Repos) EXPECT() *Repos_Expecter {
return &Repos_Expecter{mock: &_m.Mock}
}
// GetDirectories provides a mock function with given fields: ctx, repoURL, revision, project, noRevisionCache, verifyCommit
func (_m *Repos) GetDirectories(ctx context.Context, repoURL string, revision string, project string, noRevisionCache bool, verifyCommit bool) ([]string, error) {
ret := _m.Called(ctx, repoURL, revision, project, noRevisionCache, verifyCommit)
@ -43,6 +51,39 @@ func (_m *Repos) GetDirectories(ctx context.Context, repoURL string, revision st
return r0, r1
}
// Repos_GetDirectories_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetDirectories'
type Repos_GetDirectories_Call struct {
*mock.Call
}
// GetDirectories is a helper method to define mock.On call
// - ctx context.Context
// - repoURL string
// - revision string
// - project string
// - noRevisionCache bool
// - verifyCommit bool
func (_e *Repos_Expecter) GetDirectories(ctx interface{}, repoURL interface{}, revision interface{}, project interface{}, noRevisionCache interface{}, verifyCommit interface{}) *Repos_GetDirectories_Call {
return &Repos_GetDirectories_Call{Call: _e.mock.On("GetDirectories", ctx, repoURL, revision, project, noRevisionCache, verifyCommit)}
}
func (_c *Repos_GetDirectories_Call) Run(run func(ctx context.Context, repoURL string, revision string, project string, noRevisionCache bool, verifyCommit bool)) *Repos_GetDirectories_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(string), args[2].(string), args[3].(string), args[4].(bool), args[5].(bool))
})
return _c
}
func (_c *Repos_GetDirectories_Call) Return(_a0 []string, _a1 error) *Repos_GetDirectories_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Repos_GetDirectories_Call) RunAndReturn(run func(context.Context, string, string, string, bool, bool) ([]string, error)) *Repos_GetDirectories_Call {
_c.Call.Return(run)
return _c
}
// GetFiles provides a mock function with given fields: ctx, repoURL, revision, project, pattern, noRevisionCache, verifyCommit
func (_m *Repos) GetFiles(ctx context.Context, repoURL string, revision string, project string, pattern string, noRevisionCache bool, verifyCommit bool) (map[string][]byte, error) {
ret := _m.Called(ctx, repoURL, revision, project, pattern, noRevisionCache, verifyCommit)
@ -73,6 +114,40 @@ func (_m *Repos) GetFiles(ctx context.Context, repoURL string, revision string,
return r0, r1
}
// Repos_GetFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFiles'
type Repos_GetFiles_Call struct {
*mock.Call
}
// GetFiles is a helper method to define mock.On call
// - ctx context.Context
// - repoURL string
// - revision string
// - project string
// - pattern string
// - noRevisionCache bool
// - verifyCommit bool
func (_e *Repos_Expecter) GetFiles(ctx interface{}, repoURL interface{}, revision interface{}, project interface{}, pattern interface{}, noRevisionCache interface{}, verifyCommit interface{}) *Repos_GetFiles_Call {
return &Repos_GetFiles_Call{Call: _e.mock.On("GetFiles", ctx, repoURL, revision, project, pattern, noRevisionCache, verifyCommit)}
}
func (_c *Repos_GetFiles_Call) Run(run func(ctx context.Context, repoURL string, revision string, project string, pattern string, noRevisionCache bool, verifyCommit bool)) *Repos_GetFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(string), args[2].(string), args[3].(string), args[4].(string), args[5].(bool), args[6].(bool))
})
return _c
}
func (_c *Repos_GetFiles_Call) Return(_a0 map[string][]byte, _a1 error) *Repos_GetFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Repos_GetFiles_Call) RunAndReturn(run func(context.Context, string, string, string, string, bool, bool) (map[string][]byte, error)) *Repos_GetFiles_Call {
_c.Call.Return(run)
return _c
}
// NewRepos creates a new instance of Repos. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRepos(t interface {

View file

@ -1,12 +1,10 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
import (
context "context"
aws "github.com/aws/aws-sdk-go/aws"
codecommit "github.com/aws/aws-sdk-go/service/codecommit"
mock "github.com/stretchr/testify/mock"
request "github.com/aws/aws-sdk-go/aws/request"
@ -17,8 +15,16 @@ type AWSCodeCommitClient struct {
mock.Mock
}
type AWSCodeCommitClient_Expecter struct {
mock *mock.Mock
}
func (_m *AWSCodeCommitClient) EXPECT() *AWSCodeCommitClient_Expecter {
return &AWSCodeCommitClient_Expecter{mock: &_m.Mock}
}
// GetFolderWithContext provides a mock function with given fields: _a0, _a1, _a2
func (_m *AWSCodeCommitClient) GetFolderWithContext(_a0 context.Context, _a1 *codecommit.GetFolderInput, _a2 ...request.Option) (*codecommit.GetFolderOutput, error) {
func (_m *AWSCodeCommitClient) GetFolderWithContext(_a0 aws.Context, _a1 *codecommit.GetFolderInput, _a2 ...request.Option) (*codecommit.GetFolderOutput, error) {
_va := make([]interface{}, len(_a2))
for _i := range _a2 {
_va[_i] = _a2[_i]
@ -34,10 +40,10 @@ func (_m *AWSCodeCommitClient) GetFolderWithContext(_a0 context.Context, _a1 *co
var r0 *codecommit.GetFolderOutput
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.GetFolderInput, ...request.Option) (*codecommit.GetFolderOutput, error)); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.GetFolderInput, ...request.Option) (*codecommit.GetFolderOutput, error)); ok {
return rf(_a0, _a1, _a2...)
}
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.GetFolderInput, ...request.Option) *codecommit.GetFolderOutput); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.GetFolderInput, ...request.Option) *codecommit.GetFolderOutput); ok {
r0 = rf(_a0, _a1, _a2...)
} else {
if ret.Get(0) != nil {
@ -45,7 +51,7 @@ func (_m *AWSCodeCommitClient) GetFolderWithContext(_a0 context.Context, _a1 *co
}
}
if rf, ok := ret.Get(1).(func(context.Context, *codecommit.GetFolderInput, ...request.Option) error); ok {
if rf, ok := ret.Get(1).(func(aws.Context, *codecommit.GetFolderInput, ...request.Option) error); ok {
r1 = rf(_a0, _a1, _a2...)
} else {
r1 = ret.Error(1)
@ -54,8 +60,45 @@ func (_m *AWSCodeCommitClient) GetFolderWithContext(_a0 context.Context, _a1 *co
return r0, r1
}
// AWSCodeCommitClient_GetFolderWithContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFolderWithContext'
type AWSCodeCommitClient_GetFolderWithContext_Call struct {
*mock.Call
}
// GetFolderWithContext is a helper method to define mock.On call
// - _a0 aws.Context
// - _a1 *codecommit.GetFolderInput
// - _a2 ...request.Option
func (_e *AWSCodeCommitClient_Expecter) GetFolderWithContext(_a0 interface{}, _a1 interface{}, _a2 ...interface{}) *AWSCodeCommitClient_GetFolderWithContext_Call {
return &AWSCodeCommitClient_GetFolderWithContext_Call{Call: _e.mock.On("GetFolderWithContext",
append([]interface{}{_a0, _a1}, _a2...)...)}
}
func (_c *AWSCodeCommitClient_GetFolderWithContext_Call) Run(run func(_a0 aws.Context, _a1 *codecommit.GetFolderInput, _a2 ...request.Option)) *AWSCodeCommitClient_GetFolderWithContext_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]request.Option, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(request.Option)
}
}
run(args[0].(aws.Context), args[1].(*codecommit.GetFolderInput), variadicArgs...)
})
return _c
}
func (_c *AWSCodeCommitClient_GetFolderWithContext_Call) Return(_a0 *codecommit.GetFolderOutput, _a1 error) *AWSCodeCommitClient_GetFolderWithContext_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AWSCodeCommitClient_GetFolderWithContext_Call) RunAndReturn(run func(aws.Context, *codecommit.GetFolderInput, ...request.Option) (*codecommit.GetFolderOutput, error)) *AWSCodeCommitClient_GetFolderWithContext_Call {
_c.Call.Return(run)
return _c
}
// GetRepositoryWithContext provides a mock function with given fields: _a0, _a1, _a2
func (_m *AWSCodeCommitClient) GetRepositoryWithContext(_a0 context.Context, _a1 *codecommit.GetRepositoryInput, _a2 ...request.Option) (*codecommit.GetRepositoryOutput, error) {
func (_m *AWSCodeCommitClient) GetRepositoryWithContext(_a0 aws.Context, _a1 *codecommit.GetRepositoryInput, _a2 ...request.Option) (*codecommit.GetRepositoryOutput, error) {
_va := make([]interface{}, len(_a2))
for _i := range _a2 {
_va[_i] = _a2[_i]
@ -71,10 +114,10 @@ func (_m *AWSCodeCommitClient) GetRepositoryWithContext(_a0 context.Context, _a1
var r0 *codecommit.GetRepositoryOutput
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.GetRepositoryInput, ...request.Option) (*codecommit.GetRepositoryOutput, error)); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.GetRepositoryInput, ...request.Option) (*codecommit.GetRepositoryOutput, error)); ok {
return rf(_a0, _a1, _a2...)
}
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.GetRepositoryInput, ...request.Option) *codecommit.GetRepositoryOutput); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.GetRepositoryInput, ...request.Option) *codecommit.GetRepositoryOutput); ok {
r0 = rf(_a0, _a1, _a2...)
} else {
if ret.Get(0) != nil {
@ -82,7 +125,7 @@ func (_m *AWSCodeCommitClient) GetRepositoryWithContext(_a0 context.Context, _a1
}
}
if rf, ok := ret.Get(1).(func(context.Context, *codecommit.GetRepositoryInput, ...request.Option) error); ok {
if rf, ok := ret.Get(1).(func(aws.Context, *codecommit.GetRepositoryInput, ...request.Option) error); ok {
r1 = rf(_a0, _a1, _a2...)
} else {
r1 = ret.Error(1)
@ -91,8 +134,45 @@ func (_m *AWSCodeCommitClient) GetRepositoryWithContext(_a0 context.Context, _a1
return r0, r1
}
// AWSCodeCommitClient_GetRepositoryWithContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRepositoryWithContext'
type AWSCodeCommitClient_GetRepositoryWithContext_Call struct {
*mock.Call
}
// GetRepositoryWithContext is a helper method to define mock.On call
// - _a0 aws.Context
// - _a1 *codecommit.GetRepositoryInput
// - _a2 ...request.Option
func (_e *AWSCodeCommitClient_Expecter) GetRepositoryWithContext(_a0 interface{}, _a1 interface{}, _a2 ...interface{}) *AWSCodeCommitClient_GetRepositoryWithContext_Call {
return &AWSCodeCommitClient_GetRepositoryWithContext_Call{Call: _e.mock.On("GetRepositoryWithContext",
append([]interface{}{_a0, _a1}, _a2...)...)}
}
func (_c *AWSCodeCommitClient_GetRepositoryWithContext_Call) Run(run func(_a0 aws.Context, _a1 *codecommit.GetRepositoryInput, _a2 ...request.Option)) *AWSCodeCommitClient_GetRepositoryWithContext_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]request.Option, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(request.Option)
}
}
run(args[0].(aws.Context), args[1].(*codecommit.GetRepositoryInput), variadicArgs...)
})
return _c
}
func (_c *AWSCodeCommitClient_GetRepositoryWithContext_Call) Return(_a0 *codecommit.GetRepositoryOutput, _a1 error) *AWSCodeCommitClient_GetRepositoryWithContext_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AWSCodeCommitClient_GetRepositoryWithContext_Call) RunAndReturn(run func(aws.Context, *codecommit.GetRepositoryInput, ...request.Option) (*codecommit.GetRepositoryOutput, error)) *AWSCodeCommitClient_GetRepositoryWithContext_Call {
_c.Call.Return(run)
return _c
}
// ListBranchesWithContext provides a mock function with given fields: _a0, _a1, _a2
func (_m *AWSCodeCommitClient) ListBranchesWithContext(_a0 context.Context, _a1 *codecommit.ListBranchesInput, _a2 ...request.Option) (*codecommit.ListBranchesOutput, error) {
func (_m *AWSCodeCommitClient) ListBranchesWithContext(_a0 aws.Context, _a1 *codecommit.ListBranchesInput, _a2 ...request.Option) (*codecommit.ListBranchesOutput, error) {
_va := make([]interface{}, len(_a2))
for _i := range _a2 {
_va[_i] = _a2[_i]
@ -108,10 +188,10 @@ func (_m *AWSCodeCommitClient) ListBranchesWithContext(_a0 context.Context, _a1
var r0 *codecommit.ListBranchesOutput
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.ListBranchesInput, ...request.Option) (*codecommit.ListBranchesOutput, error)); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.ListBranchesInput, ...request.Option) (*codecommit.ListBranchesOutput, error)); ok {
return rf(_a0, _a1, _a2...)
}
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.ListBranchesInput, ...request.Option) *codecommit.ListBranchesOutput); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.ListBranchesInput, ...request.Option) *codecommit.ListBranchesOutput); ok {
r0 = rf(_a0, _a1, _a2...)
} else {
if ret.Get(0) != nil {
@ -119,7 +199,7 @@ func (_m *AWSCodeCommitClient) ListBranchesWithContext(_a0 context.Context, _a1
}
}
if rf, ok := ret.Get(1).(func(context.Context, *codecommit.ListBranchesInput, ...request.Option) error); ok {
if rf, ok := ret.Get(1).(func(aws.Context, *codecommit.ListBranchesInput, ...request.Option) error); ok {
r1 = rf(_a0, _a1, _a2...)
} else {
r1 = ret.Error(1)
@ -128,8 +208,45 @@ func (_m *AWSCodeCommitClient) ListBranchesWithContext(_a0 context.Context, _a1
return r0, r1
}
// AWSCodeCommitClient_ListBranchesWithContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListBranchesWithContext'
type AWSCodeCommitClient_ListBranchesWithContext_Call struct {
*mock.Call
}
// ListBranchesWithContext is a helper method to define mock.On call
// - _a0 aws.Context
// - _a1 *codecommit.ListBranchesInput
// - _a2 ...request.Option
func (_e *AWSCodeCommitClient_Expecter) ListBranchesWithContext(_a0 interface{}, _a1 interface{}, _a2 ...interface{}) *AWSCodeCommitClient_ListBranchesWithContext_Call {
return &AWSCodeCommitClient_ListBranchesWithContext_Call{Call: _e.mock.On("ListBranchesWithContext",
append([]interface{}{_a0, _a1}, _a2...)...)}
}
func (_c *AWSCodeCommitClient_ListBranchesWithContext_Call) Run(run func(_a0 aws.Context, _a1 *codecommit.ListBranchesInput, _a2 ...request.Option)) *AWSCodeCommitClient_ListBranchesWithContext_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]request.Option, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(request.Option)
}
}
run(args[0].(aws.Context), args[1].(*codecommit.ListBranchesInput), variadicArgs...)
})
return _c
}
func (_c *AWSCodeCommitClient_ListBranchesWithContext_Call) Return(_a0 *codecommit.ListBranchesOutput, _a1 error) *AWSCodeCommitClient_ListBranchesWithContext_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AWSCodeCommitClient_ListBranchesWithContext_Call) RunAndReturn(run func(aws.Context, *codecommit.ListBranchesInput, ...request.Option) (*codecommit.ListBranchesOutput, error)) *AWSCodeCommitClient_ListBranchesWithContext_Call {
_c.Call.Return(run)
return _c
}
// ListRepositoriesWithContext provides a mock function with given fields: _a0, _a1, _a2
func (_m *AWSCodeCommitClient) ListRepositoriesWithContext(_a0 context.Context, _a1 *codecommit.ListRepositoriesInput, _a2 ...request.Option) (*codecommit.ListRepositoriesOutput, error) {
func (_m *AWSCodeCommitClient) ListRepositoriesWithContext(_a0 aws.Context, _a1 *codecommit.ListRepositoriesInput, _a2 ...request.Option) (*codecommit.ListRepositoriesOutput, error) {
_va := make([]interface{}, len(_a2))
for _i := range _a2 {
_va[_i] = _a2[_i]
@ -145,10 +262,10 @@ func (_m *AWSCodeCommitClient) ListRepositoriesWithContext(_a0 context.Context,
var r0 *codecommit.ListRepositoriesOutput
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.ListRepositoriesInput, ...request.Option) (*codecommit.ListRepositoriesOutput, error)); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.ListRepositoriesInput, ...request.Option) (*codecommit.ListRepositoriesOutput, error)); ok {
return rf(_a0, _a1, _a2...)
}
if rf, ok := ret.Get(0).(func(context.Context, *codecommit.ListRepositoriesInput, ...request.Option) *codecommit.ListRepositoriesOutput); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *codecommit.ListRepositoriesInput, ...request.Option) *codecommit.ListRepositoriesOutput); ok {
r0 = rf(_a0, _a1, _a2...)
} else {
if ret.Get(0) != nil {
@ -156,7 +273,7 @@ func (_m *AWSCodeCommitClient) ListRepositoriesWithContext(_a0 context.Context,
}
}
if rf, ok := ret.Get(1).(func(context.Context, *codecommit.ListRepositoriesInput, ...request.Option) error); ok {
if rf, ok := ret.Get(1).(func(aws.Context, *codecommit.ListRepositoriesInput, ...request.Option) error); ok {
r1 = rf(_a0, _a1, _a2...)
} else {
r1 = ret.Error(1)
@ -165,6 +282,43 @@ func (_m *AWSCodeCommitClient) ListRepositoriesWithContext(_a0 context.Context,
return r0, r1
}
// AWSCodeCommitClient_ListRepositoriesWithContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListRepositoriesWithContext'
type AWSCodeCommitClient_ListRepositoriesWithContext_Call struct {
*mock.Call
}
// ListRepositoriesWithContext is a helper method to define mock.On call
// - _a0 aws.Context
// - _a1 *codecommit.ListRepositoriesInput
// - _a2 ...request.Option
func (_e *AWSCodeCommitClient_Expecter) ListRepositoriesWithContext(_a0 interface{}, _a1 interface{}, _a2 ...interface{}) *AWSCodeCommitClient_ListRepositoriesWithContext_Call {
return &AWSCodeCommitClient_ListRepositoriesWithContext_Call{Call: _e.mock.On("ListRepositoriesWithContext",
append([]interface{}{_a0, _a1}, _a2...)...)}
}
func (_c *AWSCodeCommitClient_ListRepositoriesWithContext_Call) Run(run func(_a0 aws.Context, _a1 *codecommit.ListRepositoriesInput, _a2 ...request.Option)) *AWSCodeCommitClient_ListRepositoriesWithContext_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]request.Option, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(request.Option)
}
}
run(args[0].(aws.Context), args[1].(*codecommit.ListRepositoriesInput), variadicArgs...)
})
return _c
}
func (_c *AWSCodeCommitClient_ListRepositoriesWithContext_Call) Return(_a0 *codecommit.ListRepositoriesOutput, _a1 error) *AWSCodeCommitClient_ListRepositoriesWithContext_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AWSCodeCommitClient_ListRepositoriesWithContext_Call) RunAndReturn(run func(aws.Context, *codecommit.ListRepositoriesInput, ...request.Option) (*codecommit.ListRepositoriesOutput, error)) *AWSCodeCommitClient_ListRepositoriesWithContext_Call {
_c.Call.Return(run)
return _c
}
// NewAWSCodeCommitClient creates a new instance of AWSCodeCommitClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewAWSCodeCommitClient(t interface {

View file

@ -1,12 +1,12 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
import (
context "context"
aws "github.com/aws/aws-sdk-go/aws"
mock "github.com/stretchr/testify/mock"
request "github.com/aws/aws-sdk-go/aws/request"
mock "github.com/stretchr/testify/mock"
resourcegroupstaggingapi "github.com/aws/aws-sdk-go/service/resourcegroupstaggingapi"
)
@ -16,8 +16,16 @@ type AWSTaggingClient struct {
mock.Mock
}
type AWSTaggingClient_Expecter struct {
mock *mock.Mock
}
func (_m *AWSTaggingClient) EXPECT() *AWSTaggingClient_Expecter {
return &AWSTaggingClient_Expecter{mock: &_m.Mock}
}
// GetResourcesWithContext provides a mock function with given fields: _a0, _a1, _a2
func (_m *AWSTaggingClient) GetResourcesWithContext(_a0 context.Context, _a1 *resourcegroupstaggingapi.GetResourcesInput, _a2 ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error) {
func (_m *AWSTaggingClient) GetResourcesWithContext(_a0 aws.Context, _a1 *resourcegroupstaggingapi.GetResourcesInput, _a2 ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error) {
_va := make([]interface{}, len(_a2))
for _i := range _a2 {
_va[_i] = _a2[_i]
@ -33,10 +41,10 @@ func (_m *AWSTaggingClient) GetResourcesWithContext(_a0 context.Context, _a1 *re
var r0 *resourcegroupstaggingapi.GetResourcesOutput
var r1 error
if rf, ok := ret.Get(0).(func(context.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error)); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error)); ok {
return rf(_a0, _a1, _a2...)
}
if rf, ok := ret.Get(0).(func(context.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) *resourcegroupstaggingapi.GetResourcesOutput); ok {
if rf, ok := ret.Get(0).(func(aws.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) *resourcegroupstaggingapi.GetResourcesOutput); ok {
r0 = rf(_a0, _a1, _a2...)
} else {
if ret.Get(0) != nil {
@ -44,7 +52,7 @@ func (_m *AWSTaggingClient) GetResourcesWithContext(_a0 context.Context, _a1 *re
}
}
if rf, ok := ret.Get(1).(func(context.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) error); ok {
if rf, ok := ret.Get(1).(func(aws.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) error); ok {
r1 = rf(_a0, _a1, _a2...)
} else {
r1 = ret.Error(1)
@ -53,6 +61,43 @@ func (_m *AWSTaggingClient) GetResourcesWithContext(_a0 context.Context, _a1 *re
return r0, r1
}
// AWSTaggingClient_GetResourcesWithContext_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetResourcesWithContext'
type AWSTaggingClient_GetResourcesWithContext_Call struct {
*mock.Call
}
// GetResourcesWithContext is a helper method to define mock.On call
// - _a0 aws.Context
// - _a1 *resourcegroupstaggingapi.GetResourcesInput
// - _a2 ...request.Option
func (_e *AWSTaggingClient_Expecter) GetResourcesWithContext(_a0 interface{}, _a1 interface{}, _a2 ...interface{}) *AWSTaggingClient_GetResourcesWithContext_Call {
return &AWSTaggingClient_GetResourcesWithContext_Call{Call: _e.mock.On("GetResourcesWithContext",
append([]interface{}{_a0, _a1}, _a2...)...)}
}
func (_c *AWSTaggingClient_GetResourcesWithContext_Call) Run(run func(_a0 aws.Context, _a1 *resourcegroupstaggingapi.GetResourcesInput, _a2 ...request.Option)) *AWSTaggingClient_GetResourcesWithContext_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]request.Option, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(request.Option)
}
}
run(args[0].(aws.Context), args[1].(*resourcegroupstaggingapi.GetResourcesInput), variadicArgs...)
})
return _c
}
func (_c *AWSTaggingClient_GetResourcesWithContext_Call) Return(_a0 *resourcegroupstaggingapi.GetResourcesOutput, _a1 error) *AWSTaggingClient_GetResourcesWithContext_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AWSTaggingClient_GetResourcesWithContext_Call) RunAndReturn(run func(aws.Context, *resourcegroupstaggingapi.GetResourcesInput, ...request.Option) (*resourcegroupstaggingapi.GetResourcesOutput, error)) *AWSTaggingClient_GetResourcesWithContext_Call {
_c.Call.Return(run)
return _c
}
// NewAWSTaggingClient creates a new instance of AWSTaggingClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewAWSTaggingClient(t interface {

File diff suppressed because it is too large Load diff

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -13,8 +13,16 @@ type Renderer struct {
mock.Mock
}
type Renderer_Expecter struct {
mock *mock.Mock
}
func (_m *Renderer) EXPECT() *Renderer_Expecter {
return &Renderer_Expecter{mock: &_m.Mock}
}
// RenderTemplateParams provides a mock function with given fields: tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions
func (_m *Renderer) RenderTemplateParams(tmpl *v1alpha1.Application, syncPolicy *v1alpha1.ApplicationSetSyncPolicy, params map[string]interface{}, useGoTemplate bool, goTemplateOptions []string) (*v1alpha1.Application, error) {
func (_m *Renderer) RenderTemplateParams(tmpl *v1alpha1.Application, syncPolicy *v1alpha1.ApplicationSetSyncPolicy, params map[string]any, useGoTemplate bool, goTemplateOptions []string) (*v1alpha1.Application, error) {
ret := _m.Called(tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions)
if len(ret) == 0 {
@ -23,10 +31,10 @@ func (_m *Renderer) RenderTemplateParams(tmpl *v1alpha1.Application, syncPolicy
var r0 *v1alpha1.Application
var r1 error
if rf, ok := ret.Get(0).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]interface{}, bool, []string) (*v1alpha1.Application, error)); ok {
if rf, ok := ret.Get(0).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]any, bool, []string) (*v1alpha1.Application, error)); ok {
return rf(tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions)
}
if rf, ok := ret.Get(0).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]interface{}, bool, []string) *v1alpha1.Application); ok {
if rf, ok := ret.Get(0).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]any, bool, []string) *v1alpha1.Application); ok {
r0 = rf(tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions)
} else {
if ret.Get(0) != nil {
@ -34,7 +42,7 @@ func (_m *Renderer) RenderTemplateParams(tmpl *v1alpha1.Application, syncPolicy
}
}
if rf, ok := ret.Get(1).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]interface{}, bool, []string) error); ok {
if rf, ok := ret.Get(1).(func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]any, bool, []string) error); ok {
r1 = rf(tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions)
} else {
r1 = ret.Error(1)
@ -43,8 +51,40 @@ func (_m *Renderer) RenderTemplateParams(tmpl *v1alpha1.Application, syncPolicy
return r0, r1
}
// Renderer_RenderTemplateParams_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RenderTemplateParams'
type Renderer_RenderTemplateParams_Call struct {
*mock.Call
}
// RenderTemplateParams is a helper method to define mock.On call
// - tmpl *v1alpha1.Application
// - syncPolicy *v1alpha1.ApplicationSetSyncPolicy
// - params map[string]any
// - useGoTemplate bool
// - goTemplateOptions []string
func (_e *Renderer_Expecter) RenderTemplateParams(tmpl interface{}, syncPolicy interface{}, params interface{}, useGoTemplate interface{}, goTemplateOptions interface{}) *Renderer_RenderTemplateParams_Call {
return &Renderer_RenderTemplateParams_Call{Call: _e.mock.On("RenderTemplateParams", tmpl, syncPolicy, params, useGoTemplate, goTemplateOptions)}
}
func (_c *Renderer_RenderTemplateParams_Call) Run(run func(tmpl *v1alpha1.Application, syncPolicy *v1alpha1.ApplicationSetSyncPolicy, params map[string]any, useGoTemplate bool, goTemplateOptions []string)) *Renderer_RenderTemplateParams_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Application), args[1].(*v1alpha1.ApplicationSetSyncPolicy), args[2].(map[string]any), args[3].(bool), args[4].([]string))
})
return _c
}
func (_c *Renderer_RenderTemplateParams_Call) Return(_a0 *v1alpha1.Application, _a1 error) *Renderer_RenderTemplateParams_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Renderer_RenderTemplateParams_Call) RunAndReturn(run func(*v1alpha1.Application, *v1alpha1.ApplicationSetSyncPolicy, map[string]any, bool, []string) (*v1alpha1.Application, error)) *Renderer_RenderTemplateParams_Call {
_c.Call.Return(run)
return _c
}
// Replace provides a mock function with given fields: tmpl, replaceMap, useGoTemplate, goTemplateOptions
func (_m *Renderer) Replace(tmpl string, replaceMap map[string]interface{}, useGoTemplate bool, goTemplateOptions []string) (string, error) {
func (_m *Renderer) Replace(tmpl string, replaceMap map[string]any, useGoTemplate bool, goTemplateOptions []string) (string, error) {
ret := _m.Called(tmpl, replaceMap, useGoTemplate, goTemplateOptions)
if len(ret) == 0 {
@ -53,16 +93,16 @@ func (_m *Renderer) Replace(tmpl string, replaceMap map[string]interface{}, useG
var r0 string
var r1 error
if rf, ok := ret.Get(0).(func(string, map[string]interface{}, bool, []string) (string, error)); ok {
if rf, ok := ret.Get(0).(func(string, map[string]any, bool, []string) (string, error)); ok {
return rf(tmpl, replaceMap, useGoTemplate, goTemplateOptions)
}
if rf, ok := ret.Get(0).(func(string, map[string]interface{}, bool, []string) string); ok {
if rf, ok := ret.Get(0).(func(string, map[string]any, bool, []string) string); ok {
r0 = rf(tmpl, replaceMap, useGoTemplate, goTemplateOptions)
} else {
r0 = ret.Get(0).(string)
}
if rf, ok := ret.Get(1).(func(string, map[string]interface{}, bool, []string) error); ok {
if rf, ok := ret.Get(1).(func(string, map[string]any, bool, []string) error); ok {
r1 = rf(tmpl, replaceMap, useGoTemplate, goTemplateOptions)
} else {
r1 = ret.Error(1)
@ -71,6 +111,37 @@ func (_m *Renderer) Replace(tmpl string, replaceMap map[string]interface{}, useG
return r0, r1
}
// Renderer_Replace_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Replace'
type Renderer_Replace_Call struct {
*mock.Call
}
// Replace is a helper method to define mock.On call
// - tmpl string
// - replaceMap map[string]any
// - useGoTemplate bool
// - goTemplateOptions []string
func (_e *Renderer_Expecter) Replace(tmpl interface{}, replaceMap interface{}, useGoTemplate interface{}, goTemplateOptions interface{}) *Renderer_Replace_Call {
return &Renderer_Replace_Call{Call: _e.mock.On("Replace", tmpl, replaceMap, useGoTemplate, goTemplateOptions)}
}
func (_c *Renderer_Replace_Call) Run(run func(tmpl string, replaceMap map[string]any, useGoTemplate bool, goTemplateOptions []string)) *Renderer_Replace_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(map[string]any), args[2].(bool), args[3].([]string))
})
return _c
}
func (_c *Renderer_Replace_Call) Return(_a0 string, _a1 error) *Renderer_Replace_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Renderer_Replace_Call) RunAndReturn(run func(string, map[string]any, bool, []string) (string, error)) *Renderer_Replace_Call {
_c.Call.Return(run)
return _c
}
// NewRenderer creates a new instance of Renderer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRenderer(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -14,6 +14,14 @@ type Clientset struct {
mock.Mock
}
type Clientset_Expecter struct {
mock *mock.Mock
}
func (_m *Clientset) EXPECT() *Clientset_Expecter {
return &Clientset_Expecter{mock: &_m.Mock}
}
// NewCommitServerClient provides a mock function with no fields
func (_m *Clientset) NewCommitServerClient() (io.Closer, apiclient.CommitServiceClient, error) {
ret := _m.Called()
@ -53,6 +61,33 @@ func (_m *Clientset) NewCommitServerClient() (io.Closer, apiclient.CommitService
return r0, r1, r2
}
// Clientset_NewCommitServerClient_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NewCommitServerClient'
type Clientset_NewCommitServerClient_Call struct {
*mock.Call
}
// NewCommitServerClient is a helper method to define mock.On call
func (_e *Clientset_Expecter) NewCommitServerClient() *Clientset_NewCommitServerClient_Call {
return &Clientset_NewCommitServerClient_Call{Call: _e.mock.On("NewCommitServerClient")}
}
func (_c *Clientset_NewCommitServerClient_Call) Run(run func()) *Clientset_NewCommitServerClient_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Clientset_NewCommitServerClient_Call) Return(_a0 io.Closer, _a1 apiclient.CommitServiceClient, _a2 error) *Clientset_NewCommitServerClient_Call {
_c.Call.Return(_a0, _a1, _a2)
return _c
}
func (_c *Clientset_NewCommitServerClient_Call) RunAndReturn(run func() (io.Closer, apiclient.CommitServiceClient, error)) *Clientset_NewCommitServerClient_Call {
_c.Call.Return(run)
return _c
}
// NewClientset creates a new instance of Clientset. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewClientset(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,6 +17,14 @@ type CommitServiceClient struct {
mock.Mock
}
type CommitServiceClient_Expecter struct {
mock *mock.Mock
}
func (_m *CommitServiceClient) EXPECT() *CommitServiceClient_Expecter {
return &CommitServiceClient_Expecter{mock: &_m.Mock}
}
// CommitHydratedManifests provides a mock function with given fields: ctx, in, opts
func (_m *CommitServiceClient) CommitHydratedManifests(ctx context.Context, in *apiclient.CommitHydratedManifestsRequest, opts ...grpc.CallOption) (*apiclient.CommitHydratedManifestsResponse, error) {
_va := make([]interface{}, len(opts))
@ -54,6 +62,43 @@ func (_m *CommitServiceClient) CommitHydratedManifests(ctx context.Context, in *
return r0, r1
}
// CommitServiceClient_CommitHydratedManifests_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CommitHydratedManifests'
type CommitServiceClient_CommitHydratedManifests_Call struct {
*mock.Call
}
// CommitHydratedManifests is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.CommitHydratedManifestsRequest
// - opts ...grpc.CallOption
func (_e *CommitServiceClient_Expecter) CommitHydratedManifests(ctx interface{}, in interface{}, opts ...interface{}) *CommitServiceClient_CommitHydratedManifests_Call {
return &CommitServiceClient_CommitHydratedManifests_Call{Call: _e.mock.On("CommitHydratedManifests",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *CommitServiceClient_CommitHydratedManifests_Call) Run(run func(ctx context.Context, in *apiclient.CommitHydratedManifestsRequest, opts ...grpc.CallOption)) *CommitServiceClient_CommitHydratedManifests_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.CommitHydratedManifestsRequest), variadicArgs...)
})
return _c
}
func (_c *CommitServiceClient_CommitHydratedManifests_Call) Return(_a0 *apiclient.CommitHydratedManifestsResponse, _a1 error) *CommitServiceClient_CommitHydratedManifests_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *CommitServiceClient_CommitHydratedManifests_Call) RunAndReturn(run func(context.Context, *apiclient.CommitHydratedManifestsRequest, ...grpc.CallOption) (*apiclient.CommitHydratedManifestsResponse, error)) *CommitServiceClient_CommitHydratedManifests_Call {
_c.Call.Return(run)
return _c
}
// NewCommitServiceClient creates a new instance of CommitServiceClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewCommitServiceClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -14,6 +14,14 @@ type RepoClientFactory struct {
mock.Mock
}
type RepoClientFactory_Expecter struct {
mock *mock.Mock
}
func (_m *RepoClientFactory) EXPECT() *RepoClientFactory_Expecter {
return &RepoClientFactory_Expecter{mock: &_m.Mock}
}
// NewClient provides a mock function with given fields: repo, rootPath
func (_m *RepoClientFactory) NewClient(repo *v1alpha1.Repository, rootPath string) (git.Client, error) {
ret := _m.Called(repo, rootPath)
@ -44,6 +52,35 @@ func (_m *RepoClientFactory) NewClient(repo *v1alpha1.Repository, rootPath strin
return r0, r1
}
// RepoClientFactory_NewClient_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NewClient'
type RepoClientFactory_NewClient_Call struct {
*mock.Call
}
// NewClient is a helper method to define mock.On call
// - repo *v1alpha1.Repository
// - rootPath string
func (_e *RepoClientFactory_Expecter) NewClient(repo interface{}, rootPath interface{}) *RepoClientFactory_NewClient_Call {
return &RepoClientFactory_NewClient_Call{Call: _e.mock.On("NewClient", repo, rootPath)}
}
func (_c *RepoClientFactory_NewClient_Call) Run(run func(repo *v1alpha1.Repository, rootPath string)) *RepoClientFactory_NewClient_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Repository), args[1].(string))
})
return _c
}
func (_c *RepoClientFactory_NewClient_Call) Return(_a0 git.Client, _a1 error) *RepoClientFactory_NewClient_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoClientFactory_NewClient_Call) RunAndReturn(run func(*v1alpha1.Repository, string) (git.Client, error)) *RepoClientFactory_NewClient_Call {
_c.Call.Return(run)
return _c
}
// NewRepoClientFactory creates a new instance of RepoClientFactory. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRepoClientFactory(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -25,6 +25,14 @@ type LiveStateCache struct {
mock.Mock
}
type LiveStateCache_Expecter struct {
mock *mock.Mock
}
func (_m *LiveStateCache) EXPECT() *LiveStateCache_Expecter {
return &LiveStateCache_Expecter{mock: &_m.Mock}
}
// GetClusterCache provides a mock function with given fields: server
func (_m *LiveStateCache) GetClusterCache(server *v1alpha1.Cluster) (cache.ClusterCache, error) {
ret := _m.Called(server)
@ -55,6 +63,34 @@ func (_m *LiveStateCache) GetClusterCache(server *v1alpha1.Cluster) (cache.Clust
return r0, r1
}
// LiveStateCache_GetClusterCache_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetClusterCache'
type LiveStateCache_GetClusterCache_Call struct {
*mock.Call
}
// GetClusterCache is a helper method to define mock.On call
// - server *v1alpha1.Cluster
func (_e *LiveStateCache_Expecter) GetClusterCache(server interface{}) *LiveStateCache_GetClusterCache_Call {
return &LiveStateCache_GetClusterCache_Call{Call: _e.mock.On("GetClusterCache", server)}
}
func (_c *LiveStateCache_GetClusterCache_Call) Run(run func(server *v1alpha1.Cluster)) *LiveStateCache_GetClusterCache_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster))
})
return _c
}
func (_c *LiveStateCache_GetClusterCache_Call) Return(_a0 cache.ClusterCache, _a1 error) *LiveStateCache_GetClusterCache_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *LiveStateCache_GetClusterCache_Call) RunAndReturn(run func(*v1alpha1.Cluster) (cache.ClusterCache, error)) *LiveStateCache_GetClusterCache_Call {
_c.Call.Return(run)
return _c
}
// GetClustersInfo provides a mock function with no fields
func (_m *LiveStateCache) GetClustersInfo() []cache.ClusterInfo {
ret := _m.Called()
@ -75,6 +111,33 @@ func (_m *LiveStateCache) GetClustersInfo() []cache.ClusterInfo {
return r0
}
// LiveStateCache_GetClustersInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetClustersInfo'
type LiveStateCache_GetClustersInfo_Call struct {
*mock.Call
}
// GetClustersInfo is a helper method to define mock.On call
func (_e *LiveStateCache_Expecter) GetClustersInfo() *LiveStateCache_GetClustersInfo_Call {
return &LiveStateCache_GetClustersInfo_Call{Call: _e.mock.On("GetClustersInfo")}
}
func (_c *LiveStateCache_GetClustersInfo_Call) Run(run func()) *LiveStateCache_GetClustersInfo_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *LiveStateCache_GetClustersInfo_Call) Return(_a0 []cache.ClusterInfo) *LiveStateCache_GetClustersInfo_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_GetClustersInfo_Call) RunAndReturn(run func() []cache.ClusterInfo) *LiveStateCache_GetClustersInfo_Call {
_c.Call.Return(run)
return _c
}
// GetManagedLiveObjs provides a mock function with given fields: destCluster, a, targetObjs
func (_m *LiveStateCache) GetManagedLiveObjs(destCluster *v1alpha1.Cluster, a *v1alpha1.Application, targetObjs []*unstructured.Unstructured) (map[kube.ResourceKey]*unstructured.Unstructured, error) {
ret := _m.Called(destCluster, a, targetObjs)
@ -105,6 +168,36 @@ func (_m *LiveStateCache) GetManagedLiveObjs(destCluster *v1alpha1.Cluster, a *v
return r0, r1
}
// LiveStateCache_GetManagedLiveObjs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetManagedLiveObjs'
type LiveStateCache_GetManagedLiveObjs_Call struct {
*mock.Call
}
// GetManagedLiveObjs is a helper method to define mock.On call
// - destCluster *v1alpha1.Cluster
// - a *v1alpha1.Application
// - targetObjs []*unstructured.Unstructured
func (_e *LiveStateCache_Expecter) GetManagedLiveObjs(destCluster interface{}, a interface{}, targetObjs interface{}) *LiveStateCache_GetManagedLiveObjs_Call {
return &LiveStateCache_GetManagedLiveObjs_Call{Call: _e.mock.On("GetManagedLiveObjs", destCluster, a, targetObjs)}
}
func (_c *LiveStateCache_GetManagedLiveObjs_Call) Run(run func(destCluster *v1alpha1.Cluster, a *v1alpha1.Application, targetObjs []*unstructured.Unstructured)) *LiveStateCache_GetManagedLiveObjs_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].(*v1alpha1.Application), args[2].([]*unstructured.Unstructured))
})
return _c
}
func (_c *LiveStateCache_GetManagedLiveObjs_Call) Return(_a0 map[kube.ResourceKey]*unstructured.Unstructured, _a1 error) *LiveStateCache_GetManagedLiveObjs_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *LiveStateCache_GetManagedLiveObjs_Call) RunAndReturn(run func(*v1alpha1.Cluster, *v1alpha1.Application, []*unstructured.Unstructured) (map[kube.ResourceKey]*unstructured.Unstructured, error)) *LiveStateCache_GetManagedLiveObjs_Call {
_c.Call.Return(run)
return _c
}
// GetNamespaceTopLevelResources provides a mock function with given fields: server, namespace
func (_m *LiveStateCache) GetNamespaceTopLevelResources(server *v1alpha1.Cluster, namespace string) (map[kube.ResourceKey]v1alpha1.ResourceNode, error) {
ret := _m.Called(server, namespace)
@ -135,6 +228,35 @@ func (_m *LiveStateCache) GetNamespaceTopLevelResources(server *v1alpha1.Cluster
return r0, r1
}
// LiveStateCache_GetNamespaceTopLevelResources_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetNamespaceTopLevelResources'
type LiveStateCache_GetNamespaceTopLevelResources_Call struct {
*mock.Call
}
// GetNamespaceTopLevelResources is a helper method to define mock.On call
// - server *v1alpha1.Cluster
// - namespace string
func (_e *LiveStateCache_Expecter) GetNamespaceTopLevelResources(server interface{}, namespace interface{}) *LiveStateCache_GetNamespaceTopLevelResources_Call {
return &LiveStateCache_GetNamespaceTopLevelResources_Call{Call: _e.mock.On("GetNamespaceTopLevelResources", server, namespace)}
}
func (_c *LiveStateCache_GetNamespaceTopLevelResources_Call) Run(run func(server *v1alpha1.Cluster, namespace string)) *LiveStateCache_GetNamespaceTopLevelResources_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].(string))
})
return _c
}
func (_c *LiveStateCache_GetNamespaceTopLevelResources_Call) Return(_a0 map[kube.ResourceKey]v1alpha1.ResourceNode, _a1 error) *LiveStateCache_GetNamespaceTopLevelResources_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *LiveStateCache_GetNamespaceTopLevelResources_Call) RunAndReturn(run func(*v1alpha1.Cluster, string) (map[kube.ResourceKey]v1alpha1.ResourceNode, error)) *LiveStateCache_GetNamespaceTopLevelResources_Call {
_c.Call.Return(run)
return _c
}
// GetVersionsInfo provides a mock function with given fields: server
func (_m *LiveStateCache) GetVersionsInfo(server *v1alpha1.Cluster) (string, []kube.APIResourceInfo, error) {
ret := _m.Called(server)
@ -172,6 +294,34 @@ func (_m *LiveStateCache) GetVersionsInfo(server *v1alpha1.Cluster) (string, []k
return r0, r1, r2
}
// LiveStateCache_GetVersionsInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetVersionsInfo'
type LiveStateCache_GetVersionsInfo_Call struct {
*mock.Call
}
// GetVersionsInfo is a helper method to define mock.On call
// - server *v1alpha1.Cluster
func (_e *LiveStateCache_Expecter) GetVersionsInfo(server interface{}) *LiveStateCache_GetVersionsInfo_Call {
return &LiveStateCache_GetVersionsInfo_Call{Call: _e.mock.On("GetVersionsInfo", server)}
}
func (_c *LiveStateCache_GetVersionsInfo_Call) Run(run func(server *v1alpha1.Cluster)) *LiveStateCache_GetVersionsInfo_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster))
})
return _c
}
func (_c *LiveStateCache_GetVersionsInfo_Call) Return(_a0 string, _a1 []kube.APIResourceInfo, _a2 error) *LiveStateCache_GetVersionsInfo_Call {
_c.Call.Return(_a0, _a1, _a2)
return _c
}
func (_c *LiveStateCache_GetVersionsInfo_Call) RunAndReturn(run func(*v1alpha1.Cluster) (string, []kube.APIResourceInfo, error)) *LiveStateCache_GetVersionsInfo_Call {
_c.Call.Return(run)
return _c
}
// Init provides a mock function with no fields
func (_m *LiveStateCache) Init() error {
ret := _m.Called()
@ -190,6 +340,33 @@ func (_m *LiveStateCache) Init() error {
return r0
}
// LiveStateCache_Init_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Init'
type LiveStateCache_Init_Call struct {
*mock.Call
}
// Init is a helper method to define mock.On call
func (_e *LiveStateCache_Expecter) Init() *LiveStateCache_Init_Call {
return &LiveStateCache_Init_Call{Call: _e.mock.On("Init")}
}
func (_c *LiveStateCache_Init_Call) Run(run func()) *LiveStateCache_Init_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *LiveStateCache_Init_Call) Return(_a0 error) *LiveStateCache_Init_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_Init_Call) RunAndReturn(run func() error) *LiveStateCache_Init_Call {
_c.Call.Return(run)
return _c
}
// IsNamespaced provides a mock function with given fields: server, gk
func (_m *LiveStateCache) IsNamespaced(server *v1alpha1.Cluster, gk schema.GroupKind) (bool, error) {
ret := _m.Called(server, gk)
@ -218,6 +395,35 @@ func (_m *LiveStateCache) IsNamespaced(server *v1alpha1.Cluster, gk schema.Group
return r0, r1
}
// LiveStateCache_IsNamespaced_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsNamespaced'
type LiveStateCache_IsNamespaced_Call struct {
*mock.Call
}
// IsNamespaced is a helper method to define mock.On call
// - server *v1alpha1.Cluster
// - gk schema.GroupKind
func (_e *LiveStateCache_Expecter) IsNamespaced(server interface{}, gk interface{}) *LiveStateCache_IsNamespaced_Call {
return &LiveStateCache_IsNamespaced_Call{Call: _e.mock.On("IsNamespaced", server, gk)}
}
func (_c *LiveStateCache_IsNamespaced_Call) Run(run func(server *v1alpha1.Cluster, gk schema.GroupKind)) *LiveStateCache_IsNamespaced_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].(schema.GroupKind))
})
return _c
}
func (_c *LiveStateCache_IsNamespaced_Call) Return(_a0 bool, _a1 error) *LiveStateCache_IsNamespaced_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *LiveStateCache_IsNamespaced_Call) RunAndReturn(run func(*v1alpha1.Cluster, schema.GroupKind) (bool, error)) *LiveStateCache_IsNamespaced_Call {
_c.Call.Return(run)
return _c
}
// IterateHierarchy provides a mock function with given fields: server, key, action
func (_m *LiveStateCache) IterateHierarchy(server *v1alpha1.Cluster, key kube.ResourceKey, action func(v1alpha1.ResourceNode, string) bool) error {
ret := _m.Called(server, key, action)
@ -236,6 +442,36 @@ func (_m *LiveStateCache) IterateHierarchy(server *v1alpha1.Cluster, key kube.Re
return r0
}
// LiveStateCache_IterateHierarchy_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IterateHierarchy'
type LiveStateCache_IterateHierarchy_Call struct {
*mock.Call
}
// IterateHierarchy is a helper method to define mock.On call
// - server *v1alpha1.Cluster
// - key kube.ResourceKey
// - action func(v1alpha1.ResourceNode , string) bool
func (_e *LiveStateCache_Expecter) IterateHierarchy(server interface{}, key interface{}, action interface{}) *LiveStateCache_IterateHierarchy_Call {
return &LiveStateCache_IterateHierarchy_Call{Call: _e.mock.On("IterateHierarchy", server, key, action)}
}
func (_c *LiveStateCache_IterateHierarchy_Call) Run(run func(server *v1alpha1.Cluster, key kube.ResourceKey, action func(v1alpha1.ResourceNode, string) bool)) *LiveStateCache_IterateHierarchy_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].(kube.ResourceKey), args[2].(func(v1alpha1.ResourceNode, string) bool))
})
return _c
}
func (_c *LiveStateCache_IterateHierarchy_Call) Return(_a0 error) *LiveStateCache_IterateHierarchy_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_IterateHierarchy_Call) RunAndReturn(run func(*v1alpha1.Cluster, kube.ResourceKey, func(v1alpha1.ResourceNode, string) bool) error) *LiveStateCache_IterateHierarchy_Call {
_c.Call.Return(run)
return _c
}
// IterateHierarchyV2 provides a mock function with given fields: server, keys, action
func (_m *LiveStateCache) IterateHierarchyV2(server *v1alpha1.Cluster, keys []kube.ResourceKey, action func(v1alpha1.ResourceNode, string) bool) error {
ret := _m.Called(server, keys, action)
@ -254,6 +490,36 @@ func (_m *LiveStateCache) IterateHierarchyV2(server *v1alpha1.Cluster, keys []ku
return r0
}
// LiveStateCache_IterateHierarchyV2_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IterateHierarchyV2'
type LiveStateCache_IterateHierarchyV2_Call struct {
*mock.Call
}
// IterateHierarchyV2 is a helper method to define mock.On call
// - server *v1alpha1.Cluster
// - keys []kube.ResourceKey
// - action func(v1alpha1.ResourceNode , string) bool
func (_e *LiveStateCache_Expecter) IterateHierarchyV2(server interface{}, keys interface{}, action interface{}) *LiveStateCache_IterateHierarchyV2_Call {
return &LiveStateCache_IterateHierarchyV2_Call{Call: _e.mock.On("IterateHierarchyV2", server, keys, action)}
}
func (_c *LiveStateCache_IterateHierarchyV2_Call) Run(run func(server *v1alpha1.Cluster, keys []kube.ResourceKey, action func(v1alpha1.ResourceNode, string) bool)) *LiveStateCache_IterateHierarchyV2_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].([]kube.ResourceKey), args[2].(func(v1alpha1.ResourceNode, string) bool))
})
return _c
}
func (_c *LiveStateCache_IterateHierarchyV2_Call) Return(_a0 error) *LiveStateCache_IterateHierarchyV2_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_IterateHierarchyV2_Call) RunAndReturn(run func(*v1alpha1.Cluster, []kube.ResourceKey, func(v1alpha1.ResourceNode, string) bool) error) *LiveStateCache_IterateHierarchyV2_Call {
_c.Call.Return(run)
return _c
}
// IterateResources provides a mock function with given fields: server, callback
func (_m *LiveStateCache) IterateResources(server *v1alpha1.Cluster, callback func(*cache.Resource, *controllercache.ResourceInfo)) error {
ret := _m.Called(server, callback)
@ -272,6 +538,35 @@ func (_m *LiveStateCache) IterateResources(server *v1alpha1.Cluster, callback fu
return r0
}
// LiveStateCache_IterateResources_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IterateResources'
type LiveStateCache_IterateResources_Call struct {
*mock.Call
}
// IterateResources is a helper method to define mock.On call
// - server *v1alpha1.Cluster
// - callback func(*cache.Resource , *controllercache.ResourceInfo)
func (_e *LiveStateCache_Expecter) IterateResources(server interface{}, callback interface{}) *LiveStateCache_IterateResources_Call {
return &LiveStateCache_IterateResources_Call{Call: _e.mock.On("IterateResources", server, callback)}
}
func (_c *LiveStateCache_IterateResources_Call) Run(run func(server *v1alpha1.Cluster, callback func(*cache.Resource, *controllercache.ResourceInfo))) *LiveStateCache_IterateResources_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*v1alpha1.Cluster), args[1].(func(*cache.Resource, *controllercache.ResourceInfo)))
})
return _c
}
func (_c *LiveStateCache_IterateResources_Call) Return(_a0 error) *LiveStateCache_IterateResources_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_IterateResources_Call) RunAndReturn(run func(*v1alpha1.Cluster, func(*cache.Resource, *controllercache.ResourceInfo)) error) *LiveStateCache_IterateResources_Call {
_c.Call.Return(run)
return _c
}
// Run provides a mock function with given fields: ctx
func (_m *LiveStateCache) Run(ctx context.Context) error {
ret := _m.Called(ctx)
@ -290,6 +585,34 @@ func (_m *LiveStateCache) Run(ctx context.Context) error {
return r0
}
// LiveStateCache_Run_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Run'
type LiveStateCache_Run_Call struct {
*mock.Call
}
// Run is a helper method to define mock.On call
// - ctx context.Context
func (_e *LiveStateCache_Expecter) Run(ctx interface{}) *LiveStateCache_Run_Call {
return &LiveStateCache_Run_Call{Call: _e.mock.On("Run", ctx)}
}
func (_c *LiveStateCache_Run_Call) Run(run func(ctx context.Context)) *LiveStateCache_Run_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context))
})
return _c
}
func (_c *LiveStateCache_Run_Call) Return(_a0 error) *LiveStateCache_Run_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_Run_Call) RunAndReturn(run func(context.Context) error) *LiveStateCache_Run_Call {
_c.Call.Return(run)
return _c
}
// UpdateShard provides a mock function with given fields: shard
func (_m *LiveStateCache) UpdateShard(shard int) bool {
ret := _m.Called(shard)
@ -308,6 +631,34 @@ func (_m *LiveStateCache) UpdateShard(shard int) bool {
return r0
}
// LiveStateCache_UpdateShard_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateShard'
type LiveStateCache_UpdateShard_Call struct {
*mock.Call
}
// UpdateShard is a helper method to define mock.On call
// - shard int
func (_e *LiveStateCache_Expecter) UpdateShard(shard interface{}) *LiveStateCache_UpdateShard_Call {
return &LiveStateCache_UpdateShard_Call{Call: _e.mock.On("UpdateShard", shard)}
}
func (_c *LiveStateCache_UpdateShard_Call) Run(run func(shard int)) *LiveStateCache_UpdateShard_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(int))
})
return _c
}
func (_c *LiveStateCache_UpdateShard_Call) Return(_a0 bool) *LiveStateCache_UpdateShard_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *LiveStateCache_UpdateShard_Call) RunAndReturn(run func(int) bool) *LiveStateCache_UpdateShard_Call {
_c.Call.Return(run)
return _c
}
// NewLiveStateCache creates a new instance of LiveStateCache. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewLiveStateCache(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,6 +17,14 @@ type ClusterServiceServer struct {
mock.Mock
}
type ClusterServiceServer_Expecter struct {
mock *mock.Mock
}
func (_m *ClusterServiceServer) EXPECT() *ClusterServiceServer_Expecter {
return &ClusterServiceServer_Expecter{mock: &_m.Mock}
}
// Create provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) Create(_a0 context.Context, _a1 *cluster.ClusterCreateRequest) (*v1alpha1.Cluster, error) {
ret := _m.Called(_a0, _a1)
@ -47,6 +55,35 @@ func (_m *ClusterServiceServer) Create(_a0 context.Context, _a1 *cluster.Cluster
return r0, r1
}
// ClusterServiceServer_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
type ClusterServiceServer_Create_Call struct {
*mock.Call
}
// Create is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterCreateRequest
func (_e *ClusterServiceServer_Expecter) Create(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_Create_Call {
return &ClusterServiceServer_Create_Call{Call: _e.mock.On("Create", _a0, _a1)}
}
func (_c *ClusterServiceServer_Create_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterCreateRequest)) *ClusterServiceServer_Create_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterCreateRequest))
})
return _c
}
func (_c *ClusterServiceServer_Create_Call) Return(_a0 *v1alpha1.Cluster, _a1 error) *ClusterServiceServer_Create_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_Create_Call) RunAndReturn(run func(context.Context, *cluster.ClusterCreateRequest) (*v1alpha1.Cluster, error)) *ClusterServiceServer_Create_Call {
_c.Call.Return(run)
return _c
}
// Delete provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) Delete(_a0 context.Context, _a1 *cluster.ClusterQuery) (*cluster.ClusterResponse, error) {
ret := _m.Called(_a0, _a1)
@ -77,6 +114,35 @@ func (_m *ClusterServiceServer) Delete(_a0 context.Context, _a1 *cluster.Cluster
return r0, r1
}
// ClusterServiceServer_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
type ClusterServiceServer_Delete_Call struct {
*mock.Call
}
// Delete is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterQuery
func (_e *ClusterServiceServer_Expecter) Delete(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_Delete_Call {
return &ClusterServiceServer_Delete_Call{Call: _e.mock.On("Delete", _a0, _a1)}
}
func (_c *ClusterServiceServer_Delete_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterQuery)) *ClusterServiceServer_Delete_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterQuery))
})
return _c
}
func (_c *ClusterServiceServer_Delete_Call) Return(_a0 *cluster.ClusterResponse, _a1 error) *ClusterServiceServer_Delete_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_Delete_Call) RunAndReturn(run func(context.Context, *cluster.ClusterQuery) (*cluster.ClusterResponse, error)) *ClusterServiceServer_Delete_Call {
_c.Call.Return(run)
return _c
}
// Get provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) Get(_a0 context.Context, _a1 *cluster.ClusterQuery) (*v1alpha1.Cluster, error) {
ret := _m.Called(_a0, _a1)
@ -107,6 +173,35 @@ func (_m *ClusterServiceServer) Get(_a0 context.Context, _a1 *cluster.ClusterQue
return r0, r1
}
// ClusterServiceServer_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
type ClusterServiceServer_Get_Call struct {
*mock.Call
}
// Get is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterQuery
func (_e *ClusterServiceServer_Expecter) Get(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_Get_Call {
return &ClusterServiceServer_Get_Call{Call: _e.mock.On("Get", _a0, _a1)}
}
func (_c *ClusterServiceServer_Get_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterQuery)) *ClusterServiceServer_Get_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterQuery))
})
return _c
}
func (_c *ClusterServiceServer_Get_Call) Return(_a0 *v1alpha1.Cluster, _a1 error) *ClusterServiceServer_Get_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_Get_Call) RunAndReturn(run func(context.Context, *cluster.ClusterQuery) (*v1alpha1.Cluster, error)) *ClusterServiceServer_Get_Call {
_c.Call.Return(run)
return _c
}
// InvalidateCache provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) InvalidateCache(_a0 context.Context, _a1 *cluster.ClusterQuery) (*v1alpha1.Cluster, error) {
ret := _m.Called(_a0, _a1)
@ -137,6 +232,35 @@ func (_m *ClusterServiceServer) InvalidateCache(_a0 context.Context, _a1 *cluste
return r0, r1
}
// ClusterServiceServer_InvalidateCache_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'InvalidateCache'
type ClusterServiceServer_InvalidateCache_Call struct {
*mock.Call
}
// InvalidateCache is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterQuery
func (_e *ClusterServiceServer_Expecter) InvalidateCache(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_InvalidateCache_Call {
return &ClusterServiceServer_InvalidateCache_Call{Call: _e.mock.On("InvalidateCache", _a0, _a1)}
}
func (_c *ClusterServiceServer_InvalidateCache_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterQuery)) *ClusterServiceServer_InvalidateCache_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterQuery))
})
return _c
}
func (_c *ClusterServiceServer_InvalidateCache_Call) Return(_a0 *v1alpha1.Cluster, _a1 error) *ClusterServiceServer_InvalidateCache_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_InvalidateCache_Call) RunAndReturn(run func(context.Context, *cluster.ClusterQuery) (*v1alpha1.Cluster, error)) *ClusterServiceServer_InvalidateCache_Call {
_c.Call.Return(run)
return _c
}
// List provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) List(_a0 context.Context, _a1 *cluster.ClusterQuery) (*v1alpha1.ClusterList, error) {
ret := _m.Called(_a0, _a1)
@ -167,6 +291,35 @@ func (_m *ClusterServiceServer) List(_a0 context.Context, _a1 *cluster.ClusterQu
return r0, r1
}
// ClusterServiceServer_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
type ClusterServiceServer_List_Call struct {
*mock.Call
}
// List is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterQuery
func (_e *ClusterServiceServer_Expecter) List(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_List_Call {
return &ClusterServiceServer_List_Call{Call: _e.mock.On("List", _a0, _a1)}
}
func (_c *ClusterServiceServer_List_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterQuery)) *ClusterServiceServer_List_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterQuery))
})
return _c
}
func (_c *ClusterServiceServer_List_Call) Return(_a0 *v1alpha1.ClusterList, _a1 error) *ClusterServiceServer_List_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_List_Call) RunAndReturn(run func(context.Context, *cluster.ClusterQuery) (*v1alpha1.ClusterList, error)) *ClusterServiceServer_List_Call {
_c.Call.Return(run)
return _c
}
// RotateAuth provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) RotateAuth(_a0 context.Context, _a1 *cluster.ClusterQuery) (*cluster.ClusterResponse, error) {
ret := _m.Called(_a0, _a1)
@ -197,6 +350,35 @@ func (_m *ClusterServiceServer) RotateAuth(_a0 context.Context, _a1 *cluster.Clu
return r0, r1
}
// ClusterServiceServer_RotateAuth_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RotateAuth'
type ClusterServiceServer_RotateAuth_Call struct {
*mock.Call
}
// RotateAuth is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterQuery
func (_e *ClusterServiceServer_Expecter) RotateAuth(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_RotateAuth_Call {
return &ClusterServiceServer_RotateAuth_Call{Call: _e.mock.On("RotateAuth", _a0, _a1)}
}
func (_c *ClusterServiceServer_RotateAuth_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterQuery)) *ClusterServiceServer_RotateAuth_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterQuery))
})
return _c
}
func (_c *ClusterServiceServer_RotateAuth_Call) Return(_a0 *cluster.ClusterResponse, _a1 error) *ClusterServiceServer_RotateAuth_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_RotateAuth_Call) RunAndReturn(run func(context.Context, *cluster.ClusterQuery) (*cluster.ClusterResponse, error)) *ClusterServiceServer_RotateAuth_Call {
_c.Call.Return(run)
return _c
}
// Update provides a mock function with given fields: _a0, _a1
func (_m *ClusterServiceServer) Update(_a0 context.Context, _a1 *cluster.ClusterUpdateRequest) (*v1alpha1.Cluster, error) {
ret := _m.Called(_a0, _a1)
@ -227,6 +409,35 @@ func (_m *ClusterServiceServer) Update(_a0 context.Context, _a1 *cluster.Cluster
return r0, r1
}
// ClusterServiceServer_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'
type ClusterServiceServer_Update_Call struct {
*mock.Call
}
// Update is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *cluster.ClusterUpdateRequest
func (_e *ClusterServiceServer_Expecter) Update(_a0 interface{}, _a1 interface{}) *ClusterServiceServer_Update_Call {
return &ClusterServiceServer_Update_Call{Call: _e.mock.On("Update", _a0, _a1)}
}
func (_c *ClusterServiceServer_Update_Call) Run(run func(_a0 context.Context, _a1 *cluster.ClusterUpdateRequest)) *ClusterServiceServer_Update_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*cluster.ClusterUpdateRequest))
})
return _c
}
func (_c *ClusterServiceServer_Update_Call) Return(_a0 *v1alpha1.Cluster, _a1 error) *ClusterServiceServer_Update_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ClusterServiceServer_Update_Call) RunAndReturn(run func(context.Context, *cluster.ClusterUpdateRequest) (*v1alpha1.Cluster, error)) *ClusterServiceServer_Update_Call {
_c.Call.Return(run)
return _c
}
// NewClusterServiceServer creates a new instance of ClusterServiceServer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewClusterServiceServer(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,6 +17,14 @@ type SessionServiceClient struct {
mock.Mock
}
type SessionServiceClient_Expecter struct {
mock *mock.Mock
}
func (_m *SessionServiceClient) EXPECT() *SessionServiceClient_Expecter {
return &SessionServiceClient_Expecter{mock: &_m.Mock}
}
// Create provides a mock function with given fields: ctx, in, opts
func (_m *SessionServiceClient) Create(ctx context.Context, in *session.SessionCreateRequest, opts ...grpc.CallOption) (*session.SessionResponse, error) {
_va := make([]interface{}, len(opts))
@ -54,6 +62,43 @@ func (_m *SessionServiceClient) Create(ctx context.Context, in *session.SessionC
return r0, r1
}
// SessionServiceClient_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
type SessionServiceClient_Create_Call struct {
*mock.Call
}
// Create is a helper method to define mock.On call
// - ctx context.Context
// - in *session.SessionCreateRequest
// - opts ...grpc.CallOption
func (_e *SessionServiceClient_Expecter) Create(ctx interface{}, in interface{}, opts ...interface{}) *SessionServiceClient_Create_Call {
return &SessionServiceClient_Create_Call{Call: _e.mock.On("Create",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *SessionServiceClient_Create_Call) Run(run func(ctx context.Context, in *session.SessionCreateRequest, opts ...grpc.CallOption)) *SessionServiceClient_Create_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*session.SessionCreateRequest), variadicArgs...)
})
return _c
}
func (_c *SessionServiceClient_Create_Call) Return(_a0 *session.SessionResponse, _a1 error) *SessionServiceClient_Create_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceClient_Create_Call) RunAndReturn(run func(context.Context, *session.SessionCreateRequest, ...grpc.CallOption) (*session.SessionResponse, error)) *SessionServiceClient_Create_Call {
_c.Call.Return(run)
return _c
}
// Delete provides a mock function with given fields: ctx, in, opts
func (_m *SessionServiceClient) Delete(ctx context.Context, in *session.SessionDeleteRequest, opts ...grpc.CallOption) (*session.SessionResponse, error) {
_va := make([]interface{}, len(opts))
@ -91,6 +136,43 @@ func (_m *SessionServiceClient) Delete(ctx context.Context, in *session.SessionD
return r0, r1
}
// SessionServiceClient_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
type SessionServiceClient_Delete_Call struct {
*mock.Call
}
// Delete is a helper method to define mock.On call
// - ctx context.Context
// - in *session.SessionDeleteRequest
// - opts ...grpc.CallOption
func (_e *SessionServiceClient_Expecter) Delete(ctx interface{}, in interface{}, opts ...interface{}) *SessionServiceClient_Delete_Call {
return &SessionServiceClient_Delete_Call{Call: _e.mock.On("Delete",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *SessionServiceClient_Delete_Call) Run(run func(ctx context.Context, in *session.SessionDeleteRequest, opts ...grpc.CallOption)) *SessionServiceClient_Delete_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*session.SessionDeleteRequest), variadicArgs...)
})
return _c
}
func (_c *SessionServiceClient_Delete_Call) Return(_a0 *session.SessionResponse, _a1 error) *SessionServiceClient_Delete_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceClient_Delete_Call) RunAndReturn(run func(context.Context, *session.SessionDeleteRequest, ...grpc.CallOption) (*session.SessionResponse, error)) *SessionServiceClient_Delete_Call {
_c.Call.Return(run)
return _c
}
// GetUserInfo provides a mock function with given fields: ctx, in, opts
func (_m *SessionServiceClient) GetUserInfo(ctx context.Context, in *session.GetUserInfoRequest, opts ...grpc.CallOption) (*session.GetUserInfoResponse, error) {
_va := make([]interface{}, len(opts))
@ -128,6 +210,43 @@ func (_m *SessionServiceClient) GetUserInfo(ctx context.Context, in *session.Get
return r0, r1
}
// SessionServiceClient_GetUserInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUserInfo'
type SessionServiceClient_GetUserInfo_Call struct {
*mock.Call
}
// GetUserInfo is a helper method to define mock.On call
// - ctx context.Context
// - in *session.GetUserInfoRequest
// - opts ...grpc.CallOption
func (_e *SessionServiceClient_Expecter) GetUserInfo(ctx interface{}, in interface{}, opts ...interface{}) *SessionServiceClient_GetUserInfo_Call {
return &SessionServiceClient_GetUserInfo_Call{Call: _e.mock.On("GetUserInfo",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *SessionServiceClient_GetUserInfo_Call) Run(run func(ctx context.Context, in *session.GetUserInfoRequest, opts ...grpc.CallOption)) *SessionServiceClient_GetUserInfo_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*session.GetUserInfoRequest), variadicArgs...)
})
return _c
}
func (_c *SessionServiceClient_GetUserInfo_Call) Return(_a0 *session.GetUserInfoResponse, _a1 error) *SessionServiceClient_GetUserInfo_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceClient_GetUserInfo_Call) RunAndReturn(run func(context.Context, *session.GetUserInfoRequest, ...grpc.CallOption) (*session.GetUserInfoResponse, error)) *SessionServiceClient_GetUserInfo_Call {
_c.Call.Return(run)
return _c
}
// NewSessionServiceClient creates a new instance of SessionServiceClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewSessionServiceClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -14,6 +14,14 @@ type SessionServiceServer struct {
mock.Mock
}
type SessionServiceServer_Expecter struct {
mock *mock.Mock
}
func (_m *SessionServiceServer) EXPECT() *SessionServiceServer_Expecter {
return &SessionServiceServer_Expecter{mock: &_m.Mock}
}
// Create provides a mock function with given fields: _a0, _a1
func (_m *SessionServiceServer) Create(_a0 context.Context, _a1 *session.SessionCreateRequest) (*session.SessionResponse, error) {
ret := _m.Called(_a0, _a1)
@ -44,6 +52,35 @@ func (_m *SessionServiceServer) Create(_a0 context.Context, _a1 *session.Session
return r0, r1
}
// SessionServiceServer_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
type SessionServiceServer_Create_Call struct {
*mock.Call
}
// Create is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *session.SessionCreateRequest
func (_e *SessionServiceServer_Expecter) Create(_a0 interface{}, _a1 interface{}) *SessionServiceServer_Create_Call {
return &SessionServiceServer_Create_Call{Call: _e.mock.On("Create", _a0, _a1)}
}
func (_c *SessionServiceServer_Create_Call) Run(run func(_a0 context.Context, _a1 *session.SessionCreateRequest)) *SessionServiceServer_Create_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*session.SessionCreateRequest))
})
return _c
}
func (_c *SessionServiceServer_Create_Call) Return(_a0 *session.SessionResponse, _a1 error) *SessionServiceServer_Create_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceServer_Create_Call) RunAndReturn(run func(context.Context, *session.SessionCreateRequest) (*session.SessionResponse, error)) *SessionServiceServer_Create_Call {
_c.Call.Return(run)
return _c
}
// Delete provides a mock function with given fields: _a0, _a1
func (_m *SessionServiceServer) Delete(_a0 context.Context, _a1 *session.SessionDeleteRequest) (*session.SessionResponse, error) {
ret := _m.Called(_a0, _a1)
@ -74,6 +111,35 @@ func (_m *SessionServiceServer) Delete(_a0 context.Context, _a1 *session.Session
return r0, r1
}
// SessionServiceServer_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
type SessionServiceServer_Delete_Call struct {
*mock.Call
}
// Delete is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *session.SessionDeleteRequest
func (_e *SessionServiceServer_Expecter) Delete(_a0 interface{}, _a1 interface{}) *SessionServiceServer_Delete_Call {
return &SessionServiceServer_Delete_Call{Call: _e.mock.On("Delete", _a0, _a1)}
}
func (_c *SessionServiceServer_Delete_Call) Run(run func(_a0 context.Context, _a1 *session.SessionDeleteRequest)) *SessionServiceServer_Delete_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*session.SessionDeleteRequest))
})
return _c
}
func (_c *SessionServiceServer_Delete_Call) Return(_a0 *session.SessionResponse, _a1 error) *SessionServiceServer_Delete_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceServer_Delete_Call) RunAndReturn(run func(context.Context, *session.SessionDeleteRequest) (*session.SessionResponse, error)) *SessionServiceServer_Delete_Call {
_c.Call.Return(run)
return _c
}
// GetUserInfo provides a mock function with given fields: _a0, _a1
func (_m *SessionServiceServer) GetUserInfo(_a0 context.Context, _a1 *session.GetUserInfoRequest) (*session.GetUserInfoResponse, error) {
ret := _m.Called(_a0, _a1)
@ -104,6 +170,35 @@ func (_m *SessionServiceServer) GetUserInfo(_a0 context.Context, _a1 *session.Ge
return r0, r1
}
// SessionServiceServer_GetUserInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUserInfo'
type SessionServiceServer_GetUserInfo_Call struct {
*mock.Call
}
// GetUserInfo is a helper method to define mock.On call
// - _a0 context.Context
// - _a1 *session.GetUserInfoRequest
func (_e *SessionServiceServer_Expecter) GetUserInfo(_a0 interface{}, _a1 interface{}) *SessionServiceServer_GetUserInfo_Call {
return &SessionServiceServer_GetUserInfo_Call{Call: _e.mock.On("GetUserInfo", _a0, _a1)}
}
func (_c *SessionServiceServer_GetUserInfo_Call) Run(run func(_a0 context.Context, _a1 *session.GetUserInfoRequest)) *SessionServiceServer_GetUserInfo_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*session.GetUserInfoRequest))
})
return _c
}
func (_c *SessionServiceServer_GetUserInfo_Call) Return(_a0 *session.GetUserInfoResponse, _a1 error) *SessionServiceServer_GetUserInfo_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SessionServiceServer_GetUserInfo_Call) RunAndReturn(run func(context.Context, *session.GetUserInfoRequest) (*session.GetUserInfoResponse, error)) *SessionServiceServer_GetUserInfo_Call {
_c.Call.Return(run)
return _c
}
// NewSessionServiceServer creates a new instance of SessionServiceServer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewSessionServiceServer(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -20,6 +20,14 @@ type AppProjectInterface struct {
mock.Mock
}
type AppProjectInterface_Expecter struct {
mock *mock.Mock
}
func (_m *AppProjectInterface) EXPECT() *AppProjectInterface_Expecter {
return &AppProjectInterface_Expecter{mock: &_m.Mock}
}
// Create provides a mock function with given fields: ctx, appProject, opts
func (_m *AppProjectInterface) Create(ctx context.Context, appProject *v1alpha1.AppProject, opts v1.CreateOptions) (*v1alpha1.AppProject, error) {
ret := _m.Called(ctx, appProject, opts)
@ -50,6 +58,36 @@ func (_m *AppProjectInterface) Create(ctx context.Context, appProject *v1alpha1.
return r0, r1
}
// AppProjectInterface_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
type AppProjectInterface_Create_Call struct {
*mock.Call
}
// Create is a helper method to define mock.On call
// - ctx context.Context
// - appProject *v1alpha1.AppProject
// - opts v1.CreateOptions
func (_e *AppProjectInterface_Expecter) Create(ctx interface{}, appProject interface{}, opts interface{}) *AppProjectInterface_Create_Call {
return &AppProjectInterface_Create_Call{Call: _e.mock.On("Create", ctx, appProject, opts)}
}
func (_c *AppProjectInterface_Create_Call) Run(run func(ctx context.Context, appProject *v1alpha1.AppProject, opts v1.CreateOptions)) *AppProjectInterface_Create_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*v1alpha1.AppProject), args[2].(v1.CreateOptions))
})
return _c
}
func (_c *AppProjectInterface_Create_Call) Return(_a0 *v1alpha1.AppProject, _a1 error) *AppProjectInterface_Create_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AppProjectInterface_Create_Call) RunAndReturn(run func(context.Context, *v1alpha1.AppProject, v1.CreateOptions) (*v1alpha1.AppProject, error)) *AppProjectInterface_Create_Call {
_c.Call.Return(run)
return _c
}
// Delete provides a mock function with given fields: ctx, name, opts
func (_m *AppProjectInterface) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {
ret := _m.Called(ctx, name, opts)
@ -68,6 +106,36 @@ func (_m *AppProjectInterface) Delete(ctx context.Context, name string, opts v1.
return r0
}
// AppProjectInterface_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
type AppProjectInterface_Delete_Call struct {
*mock.Call
}
// Delete is a helper method to define mock.On call
// - ctx context.Context
// - name string
// - opts v1.DeleteOptions
func (_e *AppProjectInterface_Expecter) Delete(ctx interface{}, name interface{}, opts interface{}) *AppProjectInterface_Delete_Call {
return &AppProjectInterface_Delete_Call{Call: _e.mock.On("Delete", ctx, name, opts)}
}
func (_c *AppProjectInterface_Delete_Call) Run(run func(ctx context.Context, name string, opts v1.DeleteOptions)) *AppProjectInterface_Delete_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(string), args[2].(v1.DeleteOptions))
})
return _c
}
func (_c *AppProjectInterface_Delete_Call) Return(_a0 error) *AppProjectInterface_Delete_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *AppProjectInterface_Delete_Call) RunAndReturn(run func(context.Context, string, v1.DeleteOptions) error) *AppProjectInterface_Delete_Call {
_c.Call.Return(run)
return _c
}
// DeleteCollection provides a mock function with given fields: ctx, opts, listOpts
func (_m *AppProjectInterface) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error {
ret := _m.Called(ctx, opts, listOpts)
@ -86,6 +154,36 @@ func (_m *AppProjectInterface) DeleteCollection(ctx context.Context, opts v1.Del
return r0
}
// AppProjectInterface_DeleteCollection_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteCollection'
type AppProjectInterface_DeleteCollection_Call struct {
*mock.Call
}
// DeleteCollection is a helper method to define mock.On call
// - ctx context.Context
// - opts v1.DeleteOptions
// - listOpts v1.ListOptions
func (_e *AppProjectInterface_Expecter) DeleteCollection(ctx interface{}, opts interface{}, listOpts interface{}) *AppProjectInterface_DeleteCollection_Call {
return &AppProjectInterface_DeleteCollection_Call{Call: _e.mock.On("DeleteCollection", ctx, opts, listOpts)}
}
func (_c *AppProjectInterface_DeleteCollection_Call) Run(run func(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions)) *AppProjectInterface_DeleteCollection_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(v1.DeleteOptions), args[2].(v1.ListOptions))
})
return _c
}
func (_c *AppProjectInterface_DeleteCollection_Call) Return(_a0 error) *AppProjectInterface_DeleteCollection_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *AppProjectInterface_DeleteCollection_Call) RunAndReturn(run func(context.Context, v1.DeleteOptions, v1.ListOptions) error) *AppProjectInterface_DeleteCollection_Call {
_c.Call.Return(run)
return _c
}
// Get provides a mock function with given fields: ctx, name, opts
func (_m *AppProjectInterface) Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.AppProject, error) {
ret := _m.Called(ctx, name, opts)
@ -116,6 +214,36 @@ func (_m *AppProjectInterface) Get(ctx context.Context, name string, opts v1.Get
return r0, r1
}
// AppProjectInterface_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
type AppProjectInterface_Get_Call struct {
*mock.Call
}
// Get is a helper method to define mock.On call
// - ctx context.Context
// - name string
// - opts v1.GetOptions
func (_e *AppProjectInterface_Expecter) Get(ctx interface{}, name interface{}, opts interface{}) *AppProjectInterface_Get_Call {
return &AppProjectInterface_Get_Call{Call: _e.mock.On("Get", ctx, name, opts)}
}
func (_c *AppProjectInterface_Get_Call) Run(run func(ctx context.Context, name string, opts v1.GetOptions)) *AppProjectInterface_Get_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(string), args[2].(v1.GetOptions))
})
return _c
}
func (_c *AppProjectInterface_Get_Call) Return(_a0 *v1alpha1.AppProject, _a1 error) *AppProjectInterface_Get_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AppProjectInterface_Get_Call) RunAndReturn(run func(context.Context, string, v1.GetOptions) (*v1alpha1.AppProject, error)) *AppProjectInterface_Get_Call {
_c.Call.Return(run)
return _c
}
// List provides a mock function with given fields: ctx, opts
func (_m *AppProjectInterface) List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.AppProjectList, error) {
ret := _m.Called(ctx, opts)
@ -146,6 +274,35 @@ func (_m *AppProjectInterface) List(ctx context.Context, opts v1.ListOptions) (*
return r0, r1
}
// AppProjectInterface_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
type AppProjectInterface_List_Call struct {
*mock.Call
}
// List is a helper method to define mock.On call
// - ctx context.Context
// - opts v1.ListOptions
func (_e *AppProjectInterface_Expecter) List(ctx interface{}, opts interface{}) *AppProjectInterface_List_Call {
return &AppProjectInterface_List_Call{Call: _e.mock.On("List", ctx, opts)}
}
func (_c *AppProjectInterface_List_Call) Run(run func(ctx context.Context, opts v1.ListOptions)) *AppProjectInterface_List_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(v1.ListOptions))
})
return _c
}
func (_c *AppProjectInterface_List_Call) Return(_a0 *v1alpha1.AppProjectList, _a1 error) *AppProjectInterface_List_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AppProjectInterface_List_Call) RunAndReturn(run func(context.Context, v1.ListOptions) (*v1alpha1.AppProjectList, error)) *AppProjectInterface_List_Call {
_c.Call.Return(run)
return _c
}
// Patch provides a mock function with given fields: ctx, name, pt, data, opts, subresources
func (_m *AppProjectInterface) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (*v1alpha1.AppProject, error) {
_va := make([]interface{}, len(subresources))
@ -183,6 +340,46 @@ func (_m *AppProjectInterface) Patch(ctx context.Context, name string, pt types.
return r0, r1
}
// AppProjectInterface_Patch_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Patch'
type AppProjectInterface_Patch_Call struct {
*mock.Call
}
// Patch is a helper method to define mock.On call
// - ctx context.Context
// - name string
// - pt types.PatchType
// - data []byte
// - opts v1.PatchOptions
// - subresources ...string
func (_e *AppProjectInterface_Expecter) Patch(ctx interface{}, name interface{}, pt interface{}, data interface{}, opts interface{}, subresources ...interface{}) *AppProjectInterface_Patch_Call {
return &AppProjectInterface_Patch_Call{Call: _e.mock.On("Patch",
append([]interface{}{ctx, name, pt, data, opts}, subresources...)...)}
}
func (_c *AppProjectInterface_Patch_Call) Run(run func(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string)) *AppProjectInterface_Patch_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]string, len(args)-5)
for i, a := range args[5:] {
if a != nil {
variadicArgs[i] = a.(string)
}
}
run(args[0].(context.Context), args[1].(string), args[2].(types.PatchType), args[3].([]byte), args[4].(v1.PatchOptions), variadicArgs...)
})
return _c
}
func (_c *AppProjectInterface_Patch_Call) Return(result *v1alpha1.AppProject, err error) *AppProjectInterface_Patch_Call {
_c.Call.Return(result, err)
return _c
}
func (_c *AppProjectInterface_Patch_Call) RunAndReturn(run func(context.Context, string, types.PatchType, []byte, v1.PatchOptions, ...string) (*v1alpha1.AppProject, error)) *AppProjectInterface_Patch_Call {
_c.Call.Return(run)
return _c
}
// Update provides a mock function with given fields: ctx, appProject, opts
func (_m *AppProjectInterface) Update(ctx context.Context, appProject *v1alpha1.AppProject, opts v1.UpdateOptions) (*v1alpha1.AppProject, error) {
ret := _m.Called(ctx, appProject, opts)
@ -213,6 +410,36 @@ func (_m *AppProjectInterface) Update(ctx context.Context, appProject *v1alpha1.
return r0, r1
}
// AppProjectInterface_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'
type AppProjectInterface_Update_Call struct {
*mock.Call
}
// Update is a helper method to define mock.On call
// - ctx context.Context
// - appProject *v1alpha1.AppProject
// - opts v1.UpdateOptions
func (_e *AppProjectInterface_Expecter) Update(ctx interface{}, appProject interface{}, opts interface{}) *AppProjectInterface_Update_Call {
return &AppProjectInterface_Update_Call{Call: _e.mock.On("Update", ctx, appProject, opts)}
}
func (_c *AppProjectInterface_Update_Call) Run(run func(ctx context.Context, appProject *v1alpha1.AppProject, opts v1.UpdateOptions)) *AppProjectInterface_Update_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*v1alpha1.AppProject), args[2].(v1.UpdateOptions))
})
return _c
}
func (_c *AppProjectInterface_Update_Call) Return(_a0 *v1alpha1.AppProject, _a1 error) *AppProjectInterface_Update_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AppProjectInterface_Update_Call) RunAndReturn(run func(context.Context, *v1alpha1.AppProject, v1.UpdateOptions) (*v1alpha1.AppProject, error)) *AppProjectInterface_Update_Call {
_c.Call.Return(run)
return _c
}
// Watch provides a mock function with given fields: ctx, opts
func (_m *AppProjectInterface) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {
ret := _m.Called(ctx, opts)
@ -243,6 +470,35 @@ func (_m *AppProjectInterface) Watch(ctx context.Context, opts v1.ListOptions) (
return r0, r1
}
// AppProjectInterface_Watch_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Watch'
type AppProjectInterface_Watch_Call struct {
*mock.Call
}
// Watch is a helper method to define mock.On call
// - ctx context.Context
// - opts v1.ListOptions
func (_e *AppProjectInterface_Expecter) Watch(ctx interface{}, opts interface{}) *AppProjectInterface_Watch_Call {
return &AppProjectInterface_Watch_Call{Call: _e.mock.On("Watch", ctx, opts)}
}
func (_c *AppProjectInterface_Watch_Call) Run(run func(ctx context.Context, opts v1.ListOptions)) *AppProjectInterface_Watch_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(v1.ListOptions))
})
return _c
}
func (_c *AppProjectInterface_Watch_Call) Return(_a0 watch.Interface, _a1 error) *AppProjectInterface_Watch_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *AppProjectInterface_Watch_Call) RunAndReturn(run func(context.Context, v1.ListOptions) (watch.Interface, error)) *AppProjectInterface_Watch_Call {
_c.Call.Return(run)
return _c
}
// NewAppProjectInterface creates a new instance of AppProjectInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewAppProjectInterface(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -21,6 +21,14 @@ type RepoServerServiceClient struct {
mock.Mock
}
type RepoServerServiceClient_Expecter struct {
mock *mock.Mock
}
func (_m *RepoServerServiceClient) EXPECT() *RepoServerServiceClient_Expecter {
return &RepoServerServiceClient_Expecter{mock: &_m.Mock}
}
// GenerateManifest provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GenerateManifest(ctx context.Context, in *apiclient.ManifestRequest, opts ...grpc.CallOption) (*apiclient.ManifestResponse, error) {
_va := make([]interface{}, len(opts))
@ -58,6 +66,43 @@ func (_m *RepoServerServiceClient) GenerateManifest(ctx context.Context, in *api
return r0, r1
}
// RepoServerServiceClient_GenerateManifest_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateManifest'
type RepoServerServiceClient_GenerateManifest_Call struct {
*mock.Call
}
// GenerateManifest is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.ManifestRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GenerateManifest(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GenerateManifest_Call {
return &RepoServerServiceClient_GenerateManifest_Call{Call: _e.mock.On("GenerateManifest",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GenerateManifest_Call) Run(run func(ctx context.Context, in *apiclient.ManifestRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GenerateManifest_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.ManifestRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GenerateManifest_Call) Return(_a0 *apiclient.ManifestResponse, _a1 error) *RepoServerServiceClient_GenerateManifest_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GenerateManifest_Call) RunAndReturn(run func(context.Context, *apiclient.ManifestRequest, ...grpc.CallOption) (*apiclient.ManifestResponse, error)) *RepoServerServiceClient_GenerateManifest_Call {
_c.Call.Return(run)
return _c
}
// GenerateManifestWithFiles provides a mock function with given fields: ctx, opts
func (_m *RepoServerServiceClient) GenerateManifestWithFiles(ctx context.Context, opts ...grpc.CallOption) (apiclient.RepoServerService_GenerateManifestWithFilesClient, error) {
_va := make([]interface{}, len(opts))
@ -95,6 +140,42 @@ func (_m *RepoServerServiceClient) GenerateManifestWithFiles(ctx context.Context
return r0, r1
}
// RepoServerServiceClient_GenerateManifestWithFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateManifestWithFiles'
type RepoServerServiceClient_GenerateManifestWithFiles_Call struct {
*mock.Call
}
// GenerateManifestWithFiles is a helper method to define mock.On call
// - ctx context.Context
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GenerateManifestWithFiles(ctx interface{}, opts ...interface{}) *RepoServerServiceClient_GenerateManifestWithFiles_Call {
return &RepoServerServiceClient_GenerateManifestWithFiles_Call{Call: _e.mock.On("GenerateManifestWithFiles",
append([]interface{}{ctx}, opts...)...)}
}
func (_c *RepoServerServiceClient_GenerateManifestWithFiles_Call) Run(run func(ctx context.Context, opts ...grpc.CallOption)) *RepoServerServiceClient_GenerateManifestWithFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-1)
for i, a := range args[1:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GenerateManifestWithFiles_Call) Return(_a0 apiclient.RepoServerService_GenerateManifestWithFilesClient, _a1 error) *RepoServerServiceClient_GenerateManifestWithFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GenerateManifestWithFiles_Call) RunAndReturn(run func(context.Context, ...grpc.CallOption) (apiclient.RepoServerService_GenerateManifestWithFilesClient, error)) *RepoServerServiceClient_GenerateManifestWithFiles_Call {
_c.Call.Return(run)
return _c
}
// GetAppDetails provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetAppDetails(ctx context.Context, in *apiclient.RepoServerAppDetailsQuery, opts ...grpc.CallOption) (*apiclient.RepoAppDetailsResponse, error) {
_va := make([]interface{}, len(opts))
@ -132,6 +213,43 @@ func (_m *RepoServerServiceClient) GetAppDetails(ctx context.Context, in *apicli
return r0, r1
}
// RepoServerServiceClient_GetAppDetails_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAppDetails'
type RepoServerServiceClient_GetAppDetails_Call struct {
*mock.Call
}
// GetAppDetails is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.RepoServerAppDetailsQuery
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetAppDetails(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetAppDetails_Call {
return &RepoServerServiceClient_GetAppDetails_Call{Call: _e.mock.On("GetAppDetails",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetAppDetails_Call) Run(run func(ctx context.Context, in *apiclient.RepoServerAppDetailsQuery, opts ...grpc.CallOption)) *RepoServerServiceClient_GetAppDetails_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.RepoServerAppDetailsQuery), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetAppDetails_Call) Return(_a0 *apiclient.RepoAppDetailsResponse, _a1 error) *RepoServerServiceClient_GetAppDetails_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetAppDetails_Call) RunAndReturn(run func(context.Context, *apiclient.RepoServerAppDetailsQuery, ...grpc.CallOption) (*apiclient.RepoAppDetailsResponse, error)) *RepoServerServiceClient_GetAppDetails_Call {
_c.Call.Return(run)
return _c
}
// GetGitDirectories provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetGitDirectories(ctx context.Context, in *apiclient.GitDirectoriesRequest, opts ...grpc.CallOption) (*apiclient.GitDirectoriesResponse, error) {
_va := make([]interface{}, len(opts))
@ -169,6 +287,43 @@ func (_m *RepoServerServiceClient) GetGitDirectories(ctx context.Context, in *ap
return r0, r1
}
// RepoServerServiceClient_GetGitDirectories_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetGitDirectories'
type RepoServerServiceClient_GetGitDirectories_Call struct {
*mock.Call
}
// GetGitDirectories is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.GitDirectoriesRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetGitDirectories(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetGitDirectories_Call {
return &RepoServerServiceClient_GetGitDirectories_Call{Call: _e.mock.On("GetGitDirectories",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetGitDirectories_Call) Run(run func(ctx context.Context, in *apiclient.GitDirectoriesRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GetGitDirectories_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.GitDirectoriesRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetGitDirectories_Call) Return(_a0 *apiclient.GitDirectoriesResponse, _a1 error) *RepoServerServiceClient_GetGitDirectories_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetGitDirectories_Call) RunAndReturn(run func(context.Context, *apiclient.GitDirectoriesRequest, ...grpc.CallOption) (*apiclient.GitDirectoriesResponse, error)) *RepoServerServiceClient_GetGitDirectories_Call {
_c.Call.Return(run)
return _c
}
// GetGitFiles provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetGitFiles(ctx context.Context, in *apiclient.GitFilesRequest, opts ...grpc.CallOption) (*apiclient.GitFilesResponse, error) {
_va := make([]interface{}, len(opts))
@ -206,6 +361,43 @@ func (_m *RepoServerServiceClient) GetGitFiles(ctx context.Context, in *apiclien
return r0, r1
}
// RepoServerServiceClient_GetGitFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetGitFiles'
type RepoServerServiceClient_GetGitFiles_Call struct {
*mock.Call
}
// GetGitFiles is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.GitFilesRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetGitFiles(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetGitFiles_Call {
return &RepoServerServiceClient_GetGitFiles_Call{Call: _e.mock.On("GetGitFiles",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetGitFiles_Call) Run(run func(ctx context.Context, in *apiclient.GitFilesRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GetGitFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.GitFilesRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetGitFiles_Call) Return(_a0 *apiclient.GitFilesResponse, _a1 error) *RepoServerServiceClient_GetGitFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetGitFiles_Call) RunAndReturn(run func(context.Context, *apiclient.GitFilesRequest, ...grpc.CallOption) (*apiclient.GitFilesResponse, error)) *RepoServerServiceClient_GetGitFiles_Call {
_c.Call.Return(run)
return _c
}
// GetHelmCharts provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetHelmCharts(ctx context.Context, in *apiclient.HelmChartsRequest, opts ...grpc.CallOption) (*apiclient.HelmChartsResponse, error) {
_va := make([]interface{}, len(opts))
@ -243,6 +435,43 @@ func (_m *RepoServerServiceClient) GetHelmCharts(ctx context.Context, in *apicli
return r0, r1
}
// RepoServerServiceClient_GetHelmCharts_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetHelmCharts'
type RepoServerServiceClient_GetHelmCharts_Call struct {
*mock.Call
}
// GetHelmCharts is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.HelmChartsRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetHelmCharts(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetHelmCharts_Call {
return &RepoServerServiceClient_GetHelmCharts_Call{Call: _e.mock.On("GetHelmCharts",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetHelmCharts_Call) Run(run func(ctx context.Context, in *apiclient.HelmChartsRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GetHelmCharts_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.HelmChartsRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetHelmCharts_Call) Return(_a0 *apiclient.HelmChartsResponse, _a1 error) *RepoServerServiceClient_GetHelmCharts_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetHelmCharts_Call) RunAndReturn(run func(context.Context, *apiclient.HelmChartsRequest, ...grpc.CallOption) (*apiclient.HelmChartsResponse, error)) *RepoServerServiceClient_GetHelmCharts_Call {
_c.Call.Return(run)
return _c
}
// GetRevisionChartDetails provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetRevisionChartDetails(ctx context.Context, in *apiclient.RepoServerRevisionChartDetailsRequest, opts ...grpc.CallOption) (*v1alpha1.ChartDetails, error) {
_va := make([]interface{}, len(opts))
@ -280,6 +509,43 @@ func (_m *RepoServerServiceClient) GetRevisionChartDetails(ctx context.Context,
return r0, r1
}
// RepoServerServiceClient_GetRevisionChartDetails_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRevisionChartDetails'
type RepoServerServiceClient_GetRevisionChartDetails_Call struct {
*mock.Call
}
// GetRevisionChartDetails is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.RepoServerRevisionChartDetailsRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetRevisionChartDetails(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetRevisionChartDetails_Call {
return &RepoServerServiceClient_GetRevisionChartDetails_Call{Call: _e.mock.On("GetRevisionChartDetails",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetRevisionChartDetails_Call) Run(run func(ctx context.Context, in *apiclient.RepoServerRevisionChartDetailsRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GetRevisionChartDetails_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.RepoServerRevisionChartDetailsRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetRevisionChartDetails_Call) Return(_a0 *v1alpha1.ChartDetails, _a1 error) *RepoServerServiceClient_GetRevisionChartDetails_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetRevisionChartDetails_Call) RunAndReturn(run func(context.Context, *apiclient.RepoServerRevisionChartDetailsRequest, ...grpc.CallOption) (*v1alpha1.ChartDetails, error)) *RepoServerServiceClient_GetRevisionChartDetails_Call {
_c.Call.Return(run)
return _c
}
// GetRevisionMetadata provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) GetRevisionMetadata(ctx context.Context, in *apiclient.RepoServerRevisionMetadataRequest, opts ...grpc.CallOption) (*v1alpha1.RevisionMetadata, error) {
_va := make([]interface{}, len(opts))
@ -317,6 +583,43 @@ func (_m *RepoServerServiceClient) GetRevisionMetadata(ctx context.Context, in *
return r0, r1
}
// RepoServerServiceClient_GetRevisionMetadata_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRevisionMetadata'
type RepoServerServiceClient_GetRevisionMetadata_Call struct {
*mock.Call
}
// GetRevisionMetadata is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.RepoServerRevisionMetadataRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) GetRevisionMetadata(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_GetRevisionMetadata_Call {
return &RepoServerServiceClient_GetRevisionMetadata_Call{Call: _e.mock.On("GetRevisionMetadata",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_GetRevisionMetadata_Call) Run(run func(ctx context.Context, in *apiclient.RepoServerRevisionMetadataRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_GetRevisionMetadata_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.RepoServerRevisionMetadataRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_GetRevisionMetadata_Call) Return(_a0 *v1alpha1.RevisionMetadata, _a1 error) *RepoServerServiceClient_GetRevisionMetadata_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_GetRevisionMetadata_Call) RunAndReturn(run func(context.Context, *apiclient.RepoServerRevisionMetadataRequest, ...grpc.CallOption) (*v1alpha1.RevisionMetadata, error)) *RepoServerServiceClient_GetRevisionMetadata_Call {
_c.Call.Return(run)
return _c
}
// ListApps provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) ListApps(ctx context.Context, in *apiclient.ListAppsRequest, opts ...grpc.CallOption) (*apiclient.AppList, error) {
_va := make([]interface{}, len(opts))
@ -354,6 +657,43 @@ func (_m *RepoServerServiceClient) ListApps(ctx context.Context, in *apiclient.L
return r0, r1
}
// RepoServerServiceClient_ListApps_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListApps'
type RepoServerServiceClient_ListApps_Call struct {
*mock.Call
}
// ListApps is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.ListAppsRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) ListApps(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_ListApps_Call {
return &RepoServerServiceClient_ListApps_Call{Call: _e.mock.On("ListApps",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_ListApps_Call) Run(run func(ctx context.Context, in *apiclient.ListAppsRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_ListApps_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.ListAppsRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_ListApps_Call) Return(_a0 *apiclient.AppList, _a1 error) *RepoServerServiceClient_ListApps_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_ListApps_Call) RunAndReturn(run func(context.Context, *apiclient.ListAppsRequest, ...grpc.CallOption) (*apiclient.AppList, error)) *RepoServerServiceClient_ListApps_Call {
_c.Call.Return(run)
return _c
}
// ListPlugins provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) ListPlugins(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*apiclient.PluginList, error) {
_va := make([]interface{}, len(opts))
@ -391,6 +731,43 @@ func (_m *RepoServerServiceClient) ListPlugins(ctx context.Context, in *emptypb.
return r0, r1
}
// RepoServerServiceClient_ListPlugins_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListPlugins'
type RepoServerServiceClient_ListPlugins_Call struct {
*mock.Call
}
// ListPlugins is a helper method to define mock.On call
// - ctx context.Context
// - in *emptypb.Empty
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) ListPlugins(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_ListPlugins_Call {
return &RepoServerServiceClient_ListPlugins_Call{Call: _e.mock.On("ListPlugins",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_ListPlugins_Call) Run(run func(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption)) *RepoServerServiceClient_ListPlugins_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*emptypb.Empty), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_ListPlugins_Call) Return(_a0 *apiclient.PluginList, _a1 error) *RepoServerServiceClient_ListPlugins_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_ListPlugins_Call) RunAndReturn(run func(context.Context, *emptypb.Empty, ...grpc.CallOption) (*apiclient.PluginList, error)) *RepoServerServiceClient_ListPlugins_Call {
_c.Call.Return(run)
return _c
}
// ListRefs provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) ListRefs(ctx context.Context, in *apiclient.ListRefsRequest, opts ...grpc.CallOption) (*apiclient.Refs, error) {
_va := make([]interface{}, len(opts))
@ -428,6 +805,43 @@ func (_m *RepoServerServiceClient) ListRefs(ctx context.Context, in *apiclient.L
return r0, r1
}
// RepoServerServiceClient_ListRefs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListRefs'
type RepoServerServiceClient_ListRefs_Call struct {
*mock.Call
}
// ListRefs is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.ListRefsRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) ListRefs(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_ListRefs_Call {
return &RepoServerServiceClient_ListRefs_Call{Call: _e.mock.On("ListRefs",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_ListRefs_Call) Run(run func(ctx context.Context, in *apiclient.ListRefsRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_ListRefs_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.ListRefsRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_ListRefs_Call) Return(_a0 *apiclient.Refs, _a1 error) *RepoServerServiceClient_ListRefs_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_ListRefs_Call) RunAndReturn(run func(context.Context, *apiclient.ListRefsRequest, ...grpc.CallOption) (*apiclient.Refs, error)) *RepoServerServiceClient_ListRefs_Call {
_c.Call.Return(run)
return _c
}
// ResolveRevision provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) ResolveRevision(ctx context.Context, in *apiclient.ResolveRevisionRequest, opts ...grpc.CallOption) (*apiclient.ResolveRevisionResponse, error) {
_va := make([]interface{}, len(opts))
@ -465,6 +879,43 @@ func (_m *RepoServerServiceClient) ResolveRevision(ctx context.Context, in *apic
return r0, r1
}
// RepoServerServiceClient_ResolveRevision_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResolveRevision'
type RepoServerServiceClient_ResolveRevision_Call struct {
*mock.Call
}
// ResolveRevision is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.ResolveRevisionRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) ResolveRevision(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_ResolveRevision_Call {
return &RepoServerServiceClient_ResolveRevision_Call{Call: _e.mock.On("ResolveRevision",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_ResolveRevision_Call) Run(run func(ctx context.Context, in *apiclient.ResolveRevisionRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_ResolveRevision_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.ResolveRevisionRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_ResolveRevision_Call) Return(_a0 *apiclient.ResolveRevisionResponse, _a1 error) *RepoServerServiceClient_ResolveRevision_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_ResolveRevision_Call) RunAndReturn(run func(context.Context, *apiclient.ResolveRevisionRequest, ...grpc.CallOption) (*apiclient.ResolveRevisionResponse, error)) *RepoServerServiceClient_ResolveRevision_Call {
_c.Call.Return(run)
return _c
}
// TestRepository provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) TestRepository(ctx context.Context, in *apiclient.TestRepositoryRequest, opts ...grpc.CallOption) (*apiclient.TestRepositoryResponse, error) {
_va := make([]interface{}, len(opts))
@ -502,6 +953,43 @@ func (_m *RepoServerServiceClient) TestRepository(ctx context.Context, in *apicl
return r0, r1
}
// RepoServerServiceClient_TestRepository_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TestRepository'
type RepoServerServiceClient_TestRepository_Call struct {
*mock.Call
}
// TestRepository is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.TestRepositoryRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) TestRepository(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_TestRepository_Call {
return &RepoServerServiceClient_TestRepository_Call{Call: _e.mock.On("TestRepository",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_TestRepository_Call) Run(run func(ctx context.Context, in *apiclient.TestRepositoryRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_TestRepository_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.TestRepositoryRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_TestRepository_Call) Return(_a0 *apiclient.TestRepositoryResponse, _a1 error) *RepoServerServiceClient_TestRepository_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_TestRepository_Call) RunAndReturn(run func(context.Context, *apiclient.TestRepositoryRequest, ...grpc.CallOption) (*apiclient.TestRepositoryResponse, error)) *RepoServerServiceClient_TestRepository_Call {
_c.Call.Return(run)
return _c
}
// UpdateRevisionForPaths provides a mock function with given fields: ctx, in, opts
func (_m *RepoServerServiceClient) UpdateRevisionForPaths(ctx context.Context, in *apiclient.UpdateRevisionForPathsRequest, opts ...grpc.CallOption) (*apiclient.UpdateRevisionForPathsResponse, error) {
_va := make([]interface{}, len(opts))
@ -539,6 +1027,43 @@ func (_m *RepoServerServiceClient) UpdateRevisionForPaths(ctx context.Context, i
return r0, r1
}
// RepoServerServiceClient_UpdateRevisionForPaths_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateRevisionForPaths'
type RepoServerServiceClient_UpdateRevisionForPaths_Call struct {
*mock.Call
}
// UpdateRevisionForPaths is a helper method to define mock.On call
// - ctx context.Context
// - in *apiclient.UpdateRevisionForPathsRequest
// - opts ...grpc.CallOption
func (_e *RepoServerServiceClient_Expecter) UpdateRevisionForPaths(ctx interface{}, in interface{}, opts ...interface{}) *RepoServerServiceClient_UpdateRevisionForPaths_Call {
return &RepoServerServiceClient_UpdateRevisionForPaths_Call{Call: _e.mock.On("UpdateRevisionForPaths",
append([]interface{}{ctx, in}, opts...)...)}
}
func (_c *RepoServerServiceClient_UpdateRevisionForPaths_Call) Run(run func(ctx context.Context, in *apiclient.UpdateRevisionForPathsRequest, opts ...grpc.CallOption)) *RepoServerServiceClient_UpdateRevisionForPaths_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]grpc.CallOption, len(args)-2)
for i, a := range args[2:] {
if a != nil {
variadicArgs[i] = a.(grpc.CallOption)
}
}
run(args[0].(context.Context), args[1].(*apiclient.UpdateRevisionForPathsRequest), variadicArgs...)
})
return _c
}
func (_c *RepoServerServiceClient_UpdateRevisionForPaths_Call) Return(_a0 *apiclient.UpdateRevisionForPathsResponse, _a1 error) *RepoServerServiceClient_UpdateRevisionForPaths_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerServiceClient_UpdateRevisionForPaths_Call) RunAndReturn(run func(context.Context, *apiclient.UpdateRevisionForPathsRequest, ...grpc.CallOption) (*apiclient.UpdateRevisionForPathsResponse, error)) *RepoServerServiceClient_UpdateRevisionForPaths_Call {
_c.Call.Return(run)
return _c
}
// NewRepoServerServiceClient creates a new instance of RepoServerServiceClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRepoServerServiceClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,6 +17,14 @@ type RepoServerService_GenerateManifestWithFilesClient struct {
mock.Mock
}
type RepoServerService_GenerateManifestWithFilesClient_Expecter struct {
mock *mock.Mock
}
func (_m *RepoServerService_GenerateManifestWithFilesClient) EXPECT() *RepoServerService_GenerateManifestWithFilesClient_Expecter {
return &RepoServerService_GenerateManifestWithFilesClient_Expecter{mock: &_m.Mock}
}
// CloseAndRecv provides a mock function with no fields
func (_m *RepoServerService_GenerateManifestWithFilesClient) CloseAndRecv() (*apiclient.ManifestResponse, error) {
ret := _m.Called()
@ -47,6 +55,33 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) CloseAndRecv() (*ap
return r0, r1
}
// RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CloseAndRecv'
type RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call struct {
*mock.Call
}
// CloseAndRecv is a helper method to define mock.On call
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) CloseAndRecv() *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call {
return &RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call{Call: _e.mock.On("CloseAndRecv")}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call) Run(run func()) *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call) Return(_a0 *apiclient.ManifestResponse, _a1 error) *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call) RunAndReturn(run func() (*apiclient.ManifestResponse, error)) *RepoServerService_GenerateManifestWithFilesClient_CloseAndRecv_Call {
_c.Call.Return(run)
return _c
}
// CloseSend provides a mock function with no fields
func (_m *RepoServerService_GenerateManifestWithFilesClient) CloseSend() error {
ret := _m.Called()
@ -65,6 +100,33 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) CloseSend() error {
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CloseSend'
type RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call struct {
*mock.Call
}
// CloseSend is a helper method to define mock.On call
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) CloseSend() *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call {
return &RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call{Call: _e.mock.On("CloseSend")}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call) Run(run func()) *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call) Return(_a0 error) *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call) RunAndReturn(run func() error) *RepoServerService_GenerateManifestWithFilesClient_CloseSend_Call {
_c.Call.Return(run)
return _c
}
// Context provides a mock function with no fields
func (_m *RepoServerService_GenerateManifestWithFilesClient) Context() context.Context {
ret := _m.Called()
@ -85,6 +147,33 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) Context() context.C
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_Context_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Context'
type RepoServerService_GenerateManifestWithFilesClient_Context_Call struct {
*mock.Call
}
// Context is a helper method to define mock.On call
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) Context() *RepoServerService_GenerateManifestWithFilesClient_Context_Call {
return &RepoServerService_GenerateManifestWithFilesClient_Context_Call{Call: _e.mock.On("Context")}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Context_Call) Run(run func()) *RepoServerService_GenerateManifestWithFilesClient_Context_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Context_Call) Return(_a0 context.Context) *RepoServerService_GenerateManifestWithFilesClient_Context_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Context_Call) RunAndReturn(run func() context.Context) *RepoServerService_GenerateManifestWithFilesClient_Context_Call {
_c.Call.Return(run)
return _c
}
// Header provides a mock function with no fields
func (_m *RepoServerService_GenerateManifestWithFilesClient) Header() (metadata.MD, error) {
ret := _m.Called()
@ -115,8 +204,35 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) Header() (metadata.
return r0, r1
}
// RepoServerService_GenerateManifestWithFilesClient_Header_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Header'
type RepoServerService_GenerateManifestWithFilesClient_Header_Call struct {
*mock.Call
}
// Header is a helper method to define mock.On call
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) Header() *RepoServerService_GenerateManifestWithFilesClient_Header_Call {
return &RepoServerService_GenerateManifestWithFilesClient_Header_Call{Call: _e.mock.On("Header")}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Header_Call) Run(run func()) *RepoServerService_GenerateManifestWithFilesClient_Header_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Header_Call) Return(_a0 metadata.MD, _a1 error) *RepoServerService_GenerateManifestWithFilesClient_Header_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Header_Call) RunAndReturn(run func() (metadata.MD, error)) *RepoServerService_GenerateManifestWithFilesClient_Header_Call {
_c.Call.Return(run)
return _c
}
// RecvMsg provides a mock function with given fields: m
func (_m *RepoServerService_GenerateManifestWithFilesClient) RecvMsg(m interface{}) error {
func (_m *RepoServerService_GenerateManifestWithFilesClient) RecvMsg(m any) error {
ret := _m.Called(m)
if len(ret) == 0 {
@ -124,7 +240,7 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) RecvMsg(m interface
}
var r0 error
if rf, ok := ret.Get(0).(func(interface{}) error); ok {
if rf, ok := ret.Get(0).(func(any) error); ok {
r0 = rf(m)
} else {
r0 = ret.Error(0)
@ -133,6 +249,34 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) RecvMsg(m interface
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RecvMsg'
type RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call struct {
*mock.Call
}
// RecvMsg is a helper method to define mock.On call
// - m any
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) RecvMsg(m interface{}) *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call {
return &RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call{Call: _e.mock.On("RecvMsg", m)}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call) Run(run func(m any)) *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(any))
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call) Return(_a0 error) *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call) RunAndReturn(run func(any) error) *RepoServerService_GenerateManifestWithFilesClient_RecvMsg_Call {
_c.Call.Return(run)
return _c
}
// Send provides a mock function with given fields: _a0
func (_m *RepoServerService_GenerateManifestWithFilesClient) Send(_a0 *apiclient.ManifestRequestWithFiles) error {
ret := _m.Called(_a0)
@ -151,8 +295,36 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) Send(_a0 *apiclient
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_Send_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Send'
type RepoServerService_GenerateManifestWithFilesClient_Send_Call struct {
*mock.Call
}
// Send is a helper method to define mock.On call
// - _a0 *apiclient.ManifestRequestWithFiles
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) Send(_a0 interface{}) *RepoServerService_GenerateManifestWithFilesClient_Send_Call {
return &RepoServerService_GenerateManifestWithFilesClient_Send_Call{Call: _e.mock.On("Send", _a0)}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Send_Call) Run(run func(_a0 *apiclient.ManifestRequestWithFiles)) *RepoServerService_GenerateManifestWithFilesClient_Send_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(*apiclient.ManifestRequestWithFiles))
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Send_Call) Return(_a0 error) *RepoServerService_GenerateManifestWithFilesClient_Send_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Send_Call) RunAndReturn(run func(*apiclient.ManifestRequestWithFiles) error) *RepoServerService_GenerateManifestWithFilesClient_Send_Call {
_c.Call.Return(run)
return _c
}
// SendMsg provides a mock function with given fields: m
func (_m *RepoServerService_GenerateManifestWithFilesClient) SendMsg(m interface{}) error {
func (_m *RepoServerService_GenerateManifestWithFilesClient) SendMsg(m any) error {
ret := _m.Called(m)
if len(ret) == 0 {
@ -160,7 +332,7 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) SendMsg(m interface
}
var r0 error
if rf, ok := ret.Get(0).(func(interface{}) error); ok {
if rf, ok := ret.Get(0).(func(any) error); ok {
r0 = rf(m)
} else {
r0 = ret.Error(0)
@ -169,6 +341,34 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) SendMsg(m interface
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SendMsg'
type RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call struct {
*mock.Call
}
// SendMsg is a helper method to define mock.On call
// - m any
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) SendMsg(m interface{}) *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call {
return &RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call{Call: _e.mock.On("SendMsg", m)}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call) Run(run func(m any)) *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(any))
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call) Return(_a0 error) *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call) RunAndReturn(run func(any) error) *RepoServerService_GenerateManifestWithFilesClient_SendMsg_Call {
_c.Call.Return(run)
return _c
}
// Trailer provides a mock function with no fields
func (_m *RepoServerService_GenerateManifestWithFilesClient) Trailer() metadata.MD {
ret := _m.Called()
@ -189,6 +389,33 @@ func (_m *RepoServerService_GenerateManifestWithFilesClient) Trailer() metadata.
return r0
}
// RepoServerService_GenerateManifestWithFilesClient_Trailer_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Trailer'
type RepoServerService_GenerateManifestWithFilesClient_Trailer_Call struct {
*mock.Call
}
// Trailer is a helper method to define mock.On call
func (_e *RepoServerService_GenerateManifestWithFilesClient_Expecter) Trailer() *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call {
return &RepoServerService_GenerateManifestWithFilesClient_Trailer_Call{Call: _e.mock.On("Trailer")}
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call) Run(run func()) *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call) Return(_a0 metadata.MD) *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call) RunAndReturn(run func() metadata.MD) *RepoServerService_GenerateManifestWithFilesClient_Trailer_Call {
_c.Call.Return(run)
return _c
}
// NewRepoServerService_GenerateManifestWithFilesClient creates a new instance of RepoServerService_GenerateManifestWithFilesClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRepoServerService_GenerateManifestWithFilesClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -12,21 +12,115 @@ type Broadcaster struct {
mock.Mock
}
type Broadcaster_Expecter struct {
mock *mock.Mock
}
func (_m *Broadcaster) EXPECT() *Broadcaster_Expecter {
return &Broadcaster_Expecter{mock: &_m.Mock}
}
// OnAdd provides a mock function with given fields: _a0, _a1
func (_m *Broadcaster) OnAdd(_a0 interface{}, _a1 bool) {
func (_m *Broadcaster) OnAdd(_a0 any, _a1 bool) {
_m.Called(_a0, _a1)
}
// Broadcaster_OnAdd_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'OnAdd'
type Broadcaster_OnAdd_Call struct {
*mock.Call
}
// OnAdd is a helper method to define mock.On call
// - _a0 any
// - _a1 bool
func (_e *Broadcaster_Expecter) OnAdd(_a0 interface{}, _a1 interface{}) *Broadcaster_OnAdd_Call {
return &Broadcaster_OnAdd_Call{Call: _e.mock.On("OnAdd", _a0, _a1)}
}
func (_c *Broadcaster_OnAdd_Call) Run(run func(_a0 any, _a1 bool)) *Broadcaster_OnAdd_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(any), args[1].(bool))
})
return _c
}
func (_c *Broadcaster_OnAdd_Call) Return() *Broadcaster_OnAdd_Call {
_c.Call.Return()
return _c
}
func (_c *Broadcaster_OnAdd_Call) RunAndReturn(run func(any, bool)) *Broadcaster_OnAdd_Call {
_c.Run(run)
return _c
}
// OnDelete provides a mock function with given fields: _a0
func (_m *Broadcaster) OnDelete(_a0 interface{}) {
func (_m *Broadcaster) OnDelete(_a0 any) {
_m.Called(_a0)
}
// Broadcaster_OnDelete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'OnDelete'
type Broadcaster_OnDelete_Call struct {
*mock.Call
}
// OnDelete is a helper method to define mock.On call
// - _a0 any
func (_e *Broadcaster_Expecter) OnDelete(_a0 interface{}) *Broadcaster_OnDelete_Call {
return &Broadcaster_OnDelete_Call{Call: _e.mock.On("OnDelete", _a0)}
}
func (_c *Broadcaster_OnDelete_Call) Run(run func(_a0 any)) *Broadcaster_OnDelete_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(any))
})
return _c
}
func (_c *Broadcaster_OnDelete_Call) Return() *Broadcaster_OnDelete_Call {
_c.Call.Return()
return _c
}
func (_c *Broadcaster_OnDelete_Call) RunAndReturn(run func(any)) *Broadcaster_OnDelete_Call {
_c.Run(run)
return _c
}
// OnUpdate provides a mock function with given fields: _a0, _a1
func (_m *Broadcaster) OnUpdate(_a0 interface{}, _a1 interface{}) {
func (_m *Broadcaster) OnUpdate(_a0 any, _a1 any) {
_m.Called(_a0, _a1)
}
// Broadcaster_OnUpdate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'OnUpdate'
type Broadcaster_OnUpdate_Call struct {
*mock.Call
}
// OnUpdate is a helper method to define mock.On call
// - _a0 any
// - _a1 any
func (_e *Broadcaster_Expecter) OnUpdate(_a0 interface{}, _a1 interface{}) *Broadcaster_OnUpdate_Call {
return &Broadcaster_OnUpdate_Call{Call: _e.mock.On("OnUpdate", _a0, _a1)}
}
func (_c *Broadcaster_OnUpdate_Call) Run(run func(_a0 any, _a1 any)) *Broadcaster_OnUpdate_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(any), args[1].(any))
})
return _c
}
func (_c *Broadcaster_OnUpdate_Call) Return() *Broadcaster_OnUpdate_Call {
_c.Call.Return()
return _c
}
func (_c *Broadcaster_OnUpdate_Call) RunAndReturn(run func(any, any)) *Broadcaster_OnUpdate_Call {
_c.Run(run)
return _c
}
// Subscribe provides a mock function with given fields: ch, filters
func (_m *Broadcaster) Subscribe(ch chan *v1alpha1.ApplicationWatchEvent, filters ...func(*v1alpha1.ApplicationWatchEvent) bool) func() {
_va := make([]interface{}, len(filters))
@ -54,6 +148,42 @@ func (_m *Broadcaster) Subscribe(ch chan *v1alpha1.ApplicationWatchEvent, filter
return r0
}
// Broadcaster_Subscribe_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Subscribe'
type Broadcaster_Subscribe_Call struct {
*mock.Call
}
// Subscribe is a helper method to define mock.On call
// - ch chan *v1alpha1.ApplicationWatchEvent
// - filters ...func(*v1alpha1.ApplicationWatchEvent) bool
func (_e *Broadcaster_Expecter) Subscribe(ch interface{}, filters ...interface{}) *Broadcaster_Subscribe_Call {
return &Broadcaster_Subscribe_Call{Call: _e.mock.On("Subscribe",
append([]interface{}{ch}, filters...)...)}
}
func (_c *Broadcaster_Subscribe_Call) Run(run func(ch chan *v1alpha1.ApplicationWatchEvent, filters ...func(*v1alpha1.ApplicationWatchEvent) bool)) *Broadcaster_Subscribe_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]func(*v1alpha1.ApplicationWatchEvent) bool, len(args)-1)
for i, a := range args[1:] {
if a != nil {
variadicArgs[i] = a.(func(*v1alpha1.ApplicationWatchEvent) bool)
}
}
run(args[0].(chan *v1alpha1.ApplicationWatchEvent), variadicArgs...)
})
return _c
}
func (_c *Broadcaster_Subscribe_Call) Return(_a0 func()) *Broadcaster_Subscribe_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Broadcaster_Subscribe_Call) RunAndReturn(run func(chan *v1alpha1.ApplicationWatchEvent, ...func(*v1alpha1.ApplicationWatchEvent) bool) func()) *Broadcaster_Subscribe_Call {
_c.Call.Return(run)
return _c
}
// NewBroadcaster creates a new instance of Broadcaster. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewBroadcaster(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -12,6 +12,14 @@ type ApplicationGetter struct {
mock.Mock
}
type ApplicationGetter_Expecter struct {
mock *mock.Mock
}
func (_m *ApplicationGetter) EXPECT() *ApplicationGetter_Expecter {
return &ApplicationGetter_Expecter{mock: &_m.Mock}
}
// Get provides a mock function with given fields: ns, name
func (_m *ApplicationGetter) Get(ns string, name string) (*v1alpha1.Application, error) {
ret := _m.Called(ns, name)
@ -42,6 +50,35 @@ func (_m *ApplicationGetter) Get(ns string, name string) (*v1alpha1.Application,
return r0, r1
}
// ApplicationGetter_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
type ApplicationGetter_Get_Call struct {
*mock.Call
}
// Get is a helper method to define mock.On call
// - ns string
// - name string
func (_e *ApplicationGetter_Expecter) Get(ns interface{}, name interface{}) *ApplicationGetter_Get_Call {
return &ApplicationGetter_Get_Call{Call: _e.mock.On("Get", ns, name)}
}
func (_c *ApplicationGetter_Get_Call) Run(run func(ns string, name string)) *ApplicationGetter_Get_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *ApplicationGetter_Get_Call) Return(_a0 *v1alpha1.Application, _a1 error) *ApplicationGetter_Get_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ApplicationGetter_Get_Call) RunAndReturn(run func(string, string) (*v1alpha1.Application, error)) *ApplicationGetter_Get_Call {
_c.Call.Return(run)
return _c
}
// NewApplicationGetter creates a new instance of ApplicationGetter. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewApplicationGetter(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -13,16 +13,82 @@ type ExtensionMetricsRegistry struct {
mock.Mock
}
type ExtensionMetricsRegistry_Expecter struct {
mock *mock.Mock
}
func (_m *ExtensionMetricsRegistry) EXPECT() *ExtensionMetricsRegistry_Expecter {
return &ExtensionMetricsRegistry_Expecter{mock: &_m.Mock}
}
// IncExtensionRequestCounter provides a mock function with given fields: _a0, status
func (_m *ExtensionMetricsRegistry) IncExtensionRequestCounter(_a0 string, status int) {
_m.Called(_a0, status)
}
// ExtensionMetricsRegistry_IncExtensionRequestCounter_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IncExtensionRequestCounter'
type ExtensionMetricsRegistry_IncExtensionRequestCounter_Call struct {
*mock.Call
}
// IncExtensionRequestCounter is a helper method to define mock.On call
// - _a0 string
// - status int
func (_e *ExtensionMetricsRegistry_Expecter) IncExtensionRequestCounter(_a0 interface{}, status interface{}) *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call {
return &ExtensionMetricsRegistry_IncExtensionRequestCounter_Call{Call: _e.mock.On("IncExtensionRequestCounter", _a0, status)}
}
func (_c *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call) Run(run func(_a0 string, status int)) *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(int))
})
return _c
}
func (_c *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call) Return() *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call {
_c.Call.Return()
return _c
}
func (_c *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call) RunAndReturn(run func(string, int)) *ExtensionMetricsRegistry_IncExtensionRequestCounter_Call {
_c.Run(run)
return _c
}
// ObserveExtensionRequestDuration provides a mock function with given fields: _a0, duration
func (_m *ExtensionMetricsRegistry) ObserveExtensionRequestDuration(_a0 string, duration time.Duration) {
_m.Called(_a0, duration)
}
// ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ObserveExtensionRequestDuration'
type ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call struct {
*mock.Call
}
// ObserveExtensionRequestDuration is a helper method to define mock.On call
// - _a0 string
// - duration time.Duration
func (_e *ExtensionMetricsRegistry_Expecter) ObserveExtensionRequestDuration(_a0 interface{}, duration interface{}) *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call {
return &ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call{Call: _e.mock.On("ObserveExtensionRequestDuration", _a0, duration)}
}
func (_c *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call) Run(run func(_a0 string, duration time.Duration)) *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(time.Duration))
})
return _c
}
func (_c *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call) Return() *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call {
_c.Call.Return()
return _c
}
func (_c *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call) RunAndReturn(run func(string, time.Duration)) *ExtensionMetricsRegistry_ObserveExtensionRequestDuration_Call {
_c.Run(run)
return _c
}
// NewExtensionMetricsRegistry creates a new instance of ExtensionMetricsRegistry. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewExtensionMetricsRegistry(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -12,6 +12,14 @@ type ProjectGetter struct {
mock.Mock
}
type ProjectGetter_Expecter struct {
mock *mock.Mock
}
func (_m *ProjectGetter) EXPECT() *ProjectGetter_Expecter {
return &ProjectGetter_Expecter{mock: &_m.Mock}
}
// Get provides a mock function with given fields: name
func (_m *ProjectGetter) Get(name string) (*v1alpha1.AppProject, error) {
ret := _m.Called(name)
@ -42,6 +50,34 @@ func (_m *ProjectGetter) Get(name string) (*v1alpha1.AppProject, error) {
return r0, r1
}
// ProjectGetter_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
type ProjectGetter_Get_Call struct {
*mock.Call
}
// Get is a helper method to define mock.On call
// - name string
func (_e *ProjectGetter_Expecter) Get(name interface{}) *ProjectGetter_Get_Call {
return &ProjectGetter_Get_Call{Call: _e.mock.On("Get", name)}
}
func (_c *ProjectGetter_Get_Call) Run(run func(name string)) *ProjectGetter_Get_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *ProjectGetter_Get_Call) Return(_a0 *v1alpha1.AppProject, _a1 error) *ProjectGetter_Get_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ProjectGetter_Get_Call) RunAndReturn(run func(string) (*v1alpha1.AppProject, error)) *ProjectGetter_Get_Call {
_c.Call.Return(run)
return _c
}
// GetClusters provides a mock function with given fields: project
func (_m *ProjectGetter) GetClusters(project string) ([]*v1alpha1.Cluster, error) {
ret := _m.Called(project)
@ -72,6 +108,34 @@ func (_m *ProjectGetter) GetClusters(project string) ([]*v1alpha1.Cluster, error
return r0, r1
}
// ProjectGetter_GetClusters_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetClusters'
type ProjectGetter_GetClusters_Call struct {
*mock.Call
}
// GetClusters is a helper method to define mock.On call
// - project string
func (_e *ProjectGetter_Expecter) GetClusters(project interface{}) *ProjectGetter_GetClusters_Call {
return &ProjectGetter_GetClusters_Call{Call: _e.mock.On("GetClusters", project)}
}
func (_c *ProjectGetter_GetClusters_Call) Run(run func(project string)) *ProjectGetter_GetClusters_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *ProjectGetter_GetClusters_Call) Return(_a0 []*v1alpha1.Cluster, _a1 error) *ProjectGetter_GetClusters_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *ProjectGetter_GetClusters_Call) RunAndReturn(run func(string) ([]*v1alpha1.Cluster, error)) *ProjectGetter_GetClusters_Call {
_c.Call.Return(run)
return _c
}
// NewProjectGetter creates a new instance of ProjectGetter. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewProjectGetter(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -9,8 +9,16 @@ type RbacEnforcer struct {
mock.Mock
}
type RbacEnforcer_Expecter struct {
mock *mock.Mock
}
func (_m *RbacEnforcer) EXPECT() *RbacEnforcer_Expecter {
return &RbacEnforcer_Expecter{mock: &_m.Mock}
}
// EnforceErr provides a mock function with given fields: rvals
func (_m *RbacEnforcer) EnforceErr(rvals ...interface{}) error {
func (_m *RbacEnforcer) EnforceErr(rvals ...any) error {
var _ca []interface{}
_ca = append(_ca, rvals...)
ret := _m.Called(_ca...)
@ -20,7 +28,7 @@ func (_m *RbacEnforcer) EnforceErr(rvals ...interface{}) error {
}
var r0 error
if rf, ok := ret.Get(0).(func(...interface{}) error); ok {
if rf, ok := ret.Get(0).(func(...any) error); ok {
r0 = rf(rvals...)
} else {
r0 = ret.Error(0)
@ -29,6 +37,41 @@ func (_m *RbacEnforcer) EnforceErr(rvals ...interface{}) error {
return r0
}
// RbacEnforcer_EnforceErr_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'EnforceErr'
type RbacEnforcer_EnforceErr_Call struct {
*mock.Call
}
// EnforceErr is a helper method to define mock.On call
// - rvals ...any
func (_e *RbacEnforcer_Expecter) EnforceErr(rvals ...interface{}) *RbacEnforcer_EnforceErr_Call {
return &RbacEnforcer_EnforceErr_Call{Call: _e.mock.On("EnforceErr",
append([]interface{}{}, rvals...)...)}
}
func (_c *RbacEnforcer_EnforceErr_Call) Run(run func(rvals ...any)) *RbacEnforcer_EnforceErr_Call {
_c.Call.Run(func(args mock.Arguments) {
variadicArgs := make([]any, len(args)-0)
for i, a := range args[0:] {
if a != nil {
variadicArgs[i] = a.(any)
}
}
run(variadicArgs...)
})
return _c
}
func (_c *RbacEnforcer_EnforceErr_Call) Return(_a0 error) *RbacEnforcer_EnforceErr_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *RbacEnforcer_EnforceErr_Call) RunAndReturn(run func(...any) error) *RbacEnforcer_EnforceErr_Call {
_c.Call.Return(run)
return _c
}
// NewRbacEnforcer creates a new instance of RbacEnforcer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewRbacEnforcer(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -12,6 +12,14 @@ type SettingsGetter struct {
mock.Mock
}
type SettingsGetter_Expecter struct {
mock *mock.Mock
}
func (_m *SettingsGetter) EXPECT() *SettingsGetter_Expecter {
return &SettingsGetter_Expecter{mock: &_m.Mock}
}
// Get provides a mock function with no fields
func (_m *SettingsGetter) Get() (*settings.ArgoCDSettings, error) {
ret := _m.Called()
@ -42,6 +50,33 @@ func (_m *SettingsGetter) Get() (*settings.ArgoCDSettings, error) {
return r0, r1
}
// SettingsGetter_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
type SettingsGetter_Get_Call struct {
*mock.Call
}
// Get is a helper method to define mock.On call
func (_e *SettingsGetter_Expecter) Get() *SettingsGetter_Get_Call {
return &SettingsGetter_Get_Call{Call: _e.mock.On("Get")}
}
func (_c *SettingsGetter_Get_Call) Run(run func()) *SettingsGetter_Get_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *SettingsGetter_Get_Call) Return(_a0 *settings.ArgoCDSettings, _a1 error) *SettingsGetter_Get_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *SettingsGetter_Get_Call) RunAndReturn(run func() (*settings.ArgoCDSettings, error)) *SettingsGetter_Get_Call {
_c.Call.Return(run)
return _c
}
// NewSettingsGetter creates a new instance of SettingsGetter. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewSettingsGetter(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -13,6 +13,14 @@ type UserGetter struct {
mock.Mock
}
type UserGetter_Expecter struct {
mock *mock.Mock
}
func (_m *UserGetter) EXPECT() *UserGetter_Expecter {
return &UserGetter_Expecter{mock: &_m.Mock}
}
// GetGroups provides a mock function with given fields: ctx
func (_m *UserGetter) GetGroups(ctx context.Context) []string {
ret := _m.Called(ctx)
@ -33,6 +41,34 @@ func (_m *UserGetter) GetGroups(ctx context.Context) []string {
return r0
}
// UserGetter_GetGroups_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetGroups'
type UserGetter_GetGroups_Call struct {
*mock.Call
}
// GetGroups is a helper method to define mock.On call
// - ctx context.Context
func (_e *UserGetter_Expecter) GetGroups(ctx interface{}) *UserGetter_GetGroups_Call {
return &UserGetter_GetGroups_Call{Call: _e.mock.On("GetGroups", ctx)}
}
func (_c *UserGetter_GetGroups_Call) Run(run func(ctx context.Context)) *UserGetter_GetGroups_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context))
})
return _c
}
func (_c *UserGetter_GetGroups_Call) Return(_a0 []string) *UserGetter_GetGroups_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *UserGetter_GetGroups_Call) RunAndReturn(run func(context.Context) []string) *UserGetter_GetGroups_Call {
_c.Call.Return(run)
return _c
}
// GetUser provides a mock function with given fields: ctx
func (_m *UserGetter) GetUser(ctx context.Context) string {
ret := _m.Called(ctx)
@ -51,6 +87,34 @@ func (_m *UserGetter) GetUser(ctx context.Context) string {
return r0
}
// UserGetter_GetUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUser'
type UserGetter_GetUser_Call struct {
*mock.Call
}
// GetUser is a helper method to define mock.On call
// - ctx context.Context
func (_e *UserGetter_Expecter) GetUser(ctx interface{}) *UserGetter_GetUser_Call {
return &UserGetter_GetUser_Call{Call: _e.mock.On("GetUser", ctx)}
}
func (_c *UserGetter_GetUser_Call) Run(run func(ctx context.Context)) *UserGetter_GetUser_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context))
})
return _c
}
func (_c *UserGetter_GetUser_Call) Return(_a0 string) *UserGetter_GetUser_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *UserGetter_GetUser_Call) RunAndReturn(run func(context.Context) string) *UserGetter_GetUser_Call {
_c.Call.Return(run)
return _c
}
// NewUserGetter creates a new instance of UserGetter. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewUserGetter(t interface {

1196
util/db/mocks/ArgoDB.go generated

File diff suppressed because it is too large Load diff

571
util/git/mocks/Client.go generated
View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -12,6 +12,14 @@ type Client struct {
mock.Mock
}
type Client_Expecter struct {
mock *mock.Mock
}
func (_m *Client) EXPECT() *Client_Expecter {
return &Client_Expecter{mock: &_m.Mock}
}
// ChangedFiles provides a mock function with given fields: revision, targetRevision
func (_m *Client) ChangedFiles(revision string, targetRevision string) ([]string, error) {
ret := _m.Called(revision, targetRevision)
@ -42,6 +50,35 @@ func (_m *Client) ChangedFiles(revision string, targetRevision string) ([]string
return r0, r1
}
// Client_ChangedFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ChangedFiles'
type Client_ChangedFiles_Call struct {
*mock.Call
}
// ChangedFiles is a helper method to define mock.On call
// - revision string
// - targetRevision string
func (_e *Client_Expecter) ChangedFiles(revision interface{}, targetRevision interface{}) *Client_ChangedFiles_Call {
return &Client_ChangedFiles_Call{Call: _e.mock.On("ChangedFiles", revision, targetRevision)}
}
func (_c *Client_ChangedFiles_Call) Run(run func(revision string, targetRevision string)) *Client_ChangedFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *Client_ChangedFiles_Call) Return(_a0 []string, _a1 error) *Client_ChangedFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_ChangedFiles_Call) RunAndReturn(run func(string, string) ([]string, error)) *Client_ChangedFiles_Call {
_c.Call.Return(run)
return _c
}
// Checkout provides a mock function with given fields: revision, submoduleEnabled
func (_m *Client) Checkout(revision string, submoduleEnabled bool) (string, error) {
ret := _m.Called(revision, submoduleEnabled)
@ -70,6 +107,35 @@ func (_m *Client) Checkout(revision string, submoduleEnabled bool) (string, erro
return r0, r1
}
// Client_Checkout_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Checkout'
type Client_Checkout_Call struct {
*mock.Call
}
// Checkout is a helper method to define mock.On call
// - revision string
// - submoduleEnabled bool
func (_e *Client_Expecter) Checkout(revision interface{}, submoduleEnabled interface{}) *Client_Checkout_Call {
return &Client_Checkout_Call{Call: _e.mock.On("Checkout", revision, submoduleEnabled)}
}
func (_c *Client_Checkout_Call) Run(run func(revision string, submoduleEnabled bool)) *Client_Checkout_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(bool))
})
return _c
}
func (_c *Client_Checkout_Call) Return(_a0 string, _a1 error) *Client_Checkout_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_Checkout_Call) RunAndReturn(run func(string, bool) (string, error)) *Client_Checkout_Call {
_c.Call.Return(run)
return _c
}
// CheckoutOrNew provides a mock function with given fields: branch, base, submoduleEnabled
func (_m *Client) CheckoutOrNew(branch string, base string, submoduleEnabled bool) (string, error) {
ret := _m.Called(branch, base, submoduleEnabled)
@ -98,6 +164,36 @@ func (_m *Client) CheckoutOrNew(branch string, base string, submoduleEnabled boo
return r0, r1
}
// Client_CheckoutOrNew_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckoutOrNew'
type Client_CheckoutOrNew_Call struct {
*mock.Call
}
// CheckoutOrNew is a helper method to define mock.On call
// - branch string
// - base string
// - submoduleEnabled bool
func (_e *Client_Expecter) CheckoutOrNew(branch interface{}, base interface{}, submoduleEnabled interface{}) *Client_CheckoutOrNew_Call {
return &Client_CheckoutOrNew_Call{Call: _e.mock.On("CheckoutOrNew", branch, base, submoduleEnabled)}
}
func (_c *Client_CheckoutOrNew_Call) Run(run func(branch string, base string, submoduleEnabled bool)) *Client_CheckoutOrNew_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string), args[2].(bool))
})
return _c
}
func (_c *Client_CheckoutOrNew_Call) Return(_a0 string, _a1 error) *Client_CheckoutOrNew_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_CheckoutOrNew_Call) RunAndReturn(run func(string, string, bool) (string, error)) *Client_CheckoutOrNew_Call {
_c.Call.Return(run)
return _c
}
// CheckoutOrOrphan provides a mock function with given fields: branch, submoduleEnabled
func (_m *Client) CheckoutOrOrphan(branch string, submoduleEnabled bool) (string, error) {
ret := _m.Called(branch, submoduleEnabled)
@ -126,6 +222,35 @@ func (_m *Client) CheckoutOrOrphan(branch string, submoduleEnabled bool) (string
return r0, r1
}
// Client_CheckoutOrOrphan_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckoutOrOrphan'
type Client_CheckoutOrOrphan_Call struct {
*mock.Call
}
// CheckoutOrOrphan is a helper method to define mock.On call
// - branch string
// - submoduleEnabled bool
func (_e *Client_Expecter) CheckoutOrOrphan(branch interface{}, submoduleEnabled interface{}) *Client_CheckoutOrOrphan_Call {
return &Client_CheckoutOrOrphan_Call{Call: _e.mock.On("CheckoutOrOrphan", branch, submoduleEnabled)}
}
func (_c *Client_CheckoutOrOrphan_Call) Run(run func(branch string, submoduleEnabled bool)) *Client_CheckoutOrOrphan_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(bool))
})
return _c
}
func (_c *Client_CheckoutOrOrphan_Call) Return(_a0 string, _a1 error) *Client_CheckoutOrOrphan_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_CheckoutOrOrphan_Call) RunAndReturn(run func(string, bool) (string, error)) *Client_CheckoutOrOrphan_Call {
_c.Call.Return(run)
return _c
}
// CommitAndPush provides a mock function with given fields: branch, message
func (_m *Client) CommitAndPush(branch string, message string) (string, error) {
ret := _m.Called(branch, message)
@ -154,6 +279,35 @@ func (_m *Client) CommitAndPush(branch string, message string) (string, error) {
return r0, r1
}
// Client_CommitAndPush_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CommitAndPush'
type Client_CommitAndPush_Call struct {
*mock.Call
}
// CommitAndPush is a helper method to define mock.On call
// - branch string
// - message string
func (_e *Client_Expecter) CommitAndPush(branch interface{}, message interface{}) *Client_CommitAndPush_Call {
return &Client_CommitAndPush_Call{Call: _e.mock.On("CommitAndPush", branch, message)}
}
func (_c *Client_CommitAndPush_Call) Run(run func(branch string, message string)) *Client_CommitAndPush_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *Client_CommitAndPush_Call) Return(_a0 string, _a1 error) *Client_CommitAndPush_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_CommitAndPush_Call) RunAndReturn(run func(string, string) (string, error)) *Client_CommitAndPush_Call {
_c.Call.Return(run)
return _c
}
// CommitSHA provides a mock function with no fields
func (_m *Client) CommitSHA() (string, error) {
ret := _m.Called()
@ -182,6 +336,33 @@ func (_m *Client) CommitSHA() (string, error) {
return r0, r1
}
// Client_CommitSHA_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CommitSHA'
type Client_CommitSHA_Call struct {
*mock.Call
}
// CommitSHA is a helper method to define mock.On call
func (_e *Client_Expecter) CommitSHA() *Client_CommitSHA_Call {
return &Client_CommitSHA_Call{Call: _e.mock.On("CommitSHA")}
}
func (_c *Client_CommitSHA_Call) Run(run func()) *Client_CommitSHA_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_CommitSHA_Call) Return(_a0 string, _a1 error) *Client_CommitSHA_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_CommitSHA_Call) RunAndReturn(run func() (string, error)) *Client_CommitSHA_Call {
_c.Call.Return(run)
return _c
}
// Fetch provides a mock function with given fields: revision
func (_m *Client) Fetch(revision string) error {
ret := _m.Called(revision)
@ -200,6 +381,34 @@ func (_m *Client) Fetch(revision string) error {
return r0
}
// Client_Fetch_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Fetch'
type Client_Fetch_Call struct {
*mock.Call
}
// Fetch is a helper method to define mock.On call
// - revision string
func (_e *Client_Expecter) Fetch(revision interface{}) *Client_Fetch_Call {
return &Client_Fetch_Call{Call: _e.mock.On("Fetch", revision)}
}
func (_c *Client_Fetch_Call) Run(run func(revision string)) *Client_Fetch_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_Fetch_Call) Return(_a0 error) *Client_Fetch_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_Fetch_Call) RunAndReturn(run func(string) error) *Client_Fetch_Call {
_c.Call.Return(run)
return _c
}
// Init provides a mock function with no fields
func (_m *Client) Init() error {
ret := _m.Called()
@ -218,6 +427,33 @@ func (_m *Client) Init() error {
return r0
}
// Client_Init_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Init'
type Client_Init_Call struct {
*mock.Call
}
// Init is a helper method to define mock.On call
func (_e *Client_Expecter) Init() *Client_Init_Call {
return &Client_Init_Call{Call: _e.mock.On("Init")}
}
func (_c *Client_Init_Call) Run(run func()) *Client_Init_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_Init_Call) Return(_a0 error) *Client_Init_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_Init_Call) RunAndReturn(run func() error) *Client_Init_Call {
_c.Call.Return(run)
return _c
}
// IsAnnotatedTag provides a mock function with given fields: _a0
func (_m *Client) IsAnnotatedTag(_a0 string) bool {
ret := _m.Called(_a0)
@ -236,6 +472,34 @@ func (_m *Client) IsAnnotatedTag(_a0 string) bool {
return r0
}
// Client_IsAnnotatedTag_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsAnnotatedTag'
type Client_IsAnnotatedTag_Call struct {
*mock.Call
}
// IsAnnotatedTag is a helper method to define mock.On call
// - _a0 string
func (_e *Client_Expecter) IsAnnotatedTag(_a0 interface{}) *Client_IsAnnotatedTag_Call {
return &Client_IsAnnotatedTag_Call{Call: _e.mock.On("IsAnnotatedTag", _a0)}
}
func (_c *Client_IsAnnotatedTag_Call) Run(run func(_a0 string)) *Client_IsAnnotatedTag_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_IsAnnotatedTag_Call) Return(_a0 bool) *Client_IsAnnotatedTag_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_IsAnnotatedTag_Call) RunAndReturn(run func(string) bool) *Client_IsAnnotatedTag_Call {
_c.Call.Return(run)
return _c
}
// IsRevisionPresent provides a mock function with given fields: revision
func (_m *Client) IsRevisionPresent(revision string) bool {
ret := _m.Called(revision)
@ -254,6 +518,34 @@ func (_m *Client) IsRevisionPresent(revision string) bool {
return r0
}
// Client_IsRevisionPresent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsRevisionPresent'
type Client_IsRevisionPresent_Call struct {
*mock.Call
}
// IsRevisionPresent is a helper method to define mock.On call
// - revision string
func (_e *Client_Expecter) IsRevisionPresent(revision interface{}) *Client_IsRevisionPresent_Call {
return &Client_IsRevisionPresent_Call{Call: _e.mock.On("IsRevisionPresent", revision)}
}
func (_c *Client_IsRevisionPresent_Call) Run(run func(revision string)) *Client_IsRevisionPresent_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_IsRevisionPresent_Call) Return(_a0 bool) *Client_IsRevisionPresent_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_IsRevisionPresent_Call) RunAndReturn(run func(string) bool) *Client_IsRevisionPresent_Call {
_c.Call.Return(run)
return _c
}
// LsFiles provides a mock function with given fields: path, enableNewGitFileGlobbing
func (_m *Client) LsFiles(path string, enableNewGitFileGlobbing bool) ([]string, error) {
ret := _m.Called(path, enableNewGitFileGlobbing)
@ -284,6 +576,35 @@ func (_m *Client) LsFiles(path string, enableNewGitFileGlobbing bool) ([]string,
return r0, r1
}
// Client_LsFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LsFiles'
type Client_LsFiles_Call struct {
*mock.Call
}
// LsFiles is a helper method to define mock.On call
// - path string
// - enableNewGitFileGlobbing bool
func (_e *Client_Expecter) LsFiles(path interface{}, enableNewGitFileGlobbing interface{}) *Client_LsFiles_Call {
return &Client_LsFiles_Call{Call: _e.mock.On("LsFiles", path, enableNewGitFileGlobbing)}
}
func (_c *Client_LsFiles_Call) Run(run func(path string, enableNewGitFileGlobbing bool)) *Client_LsFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(bool))
})
return _c
}
func (_c *Client_LsFiles_Call) Return(_a0 []string, _a1 error) *Client_LsFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_LsFiles_Call) RunAndReturn(run func(string, bool) ([]string, error)) *Client_LsFiles_Call {
_c.Call.Return(run)
return _c
}
// LsLargeFiles provides a mock function with no fields
func (_m *Client) LsLargeFiles() ([]string, error) {
ret := _m.Called()
@ -314,6 +635,33 @@ func (_m *Client) LsLargeFiles() ([]string, error) {
return r0, r1
}
// Client_LsLargeFiles_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LsLargeFiles'
type Client_LsLargeFiles_Call struct {
*mock.Call
}
// LsLargeFiles is a helper method to define mock.On call
func (_e *Client_Expecter) LsLargeFiles() *Client_LsLargeFiles_Call {
return &Client_LsLargeFiles_Call{Call: _e.mock.On("LsLargeFiles")}
}
func (_c *Client_LsLargeFiles_Call) Run(run func()) *Client_LsLargeFiles_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_LsLargeFiles_Call) Return(_a0 []string, _a1 error) *Client_LsLargeFiles_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_LsLargeFiles_Call) RunAndReturn(run func() ([]string, error)) *Client_LsLargeFiles_Call {
_c.Call.Return(run)
return _c
}
// LsRefs provides a mock function with no fields
func (_m *Client) LsRefs() (*git.Refs, error) {
ret := _m.Called()
@ -344,6 +692,33 @@ func (_m *Client) LsRefs() (*git.Refs, error) {
return r0, r1
}
// Client_LsRefs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LsRefs'
type Client_LsRefs_Call struct {
*mock.Call
}
// LsRefs is a helper method to define mock.On call
func (_e *Client_Expecter) LsRefs() *Client_LsRefs_Call {
return &Client_LsRefs_Call{Call: _e.mock.On("LsRefs")}
}
func (_c *Client_LsRefs_Call) Run(run func()) *Client_LsRefs_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_LsRefs_Call) Return(_a0 *git.Refs, _a1 error) *Client_LsRefs_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_LsRefs_Call) RunAndReturn(run func() (*git.Refs, error)) *Client_LsRefs_Call {
_c.Call.Return(run)
return _c
}
// LsRemote provides a mock function with given fields: revision
func (_m *Client) LsRemote(revision string) (string, error) {
ret := _m.Called(revision)
@ -372,6 +747,34 @@ func (_m *Client) LsRemote(revision string) (string, error) {
return r0, r1
}
// Client_LsRemote_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'LsRemote'
type Client_LsRemote_Call struct {
*mock.Call
}
// LsRemote is a helper method to define mock.On call
// - revision string
func (_e *Client_Expecter) LsRemote(revision interface{}) *Client_LsRemote_Call {
return &Client_LsRemote_Call{Call: _e.mock.On("LsRemote", revision)}
}
func (_c *Client_LsRemote_Call) Run(run func(revision string)) *Client_LsRemote_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_LsRemote_Call) Return(_a0 string, _a1 error) *Client_LsRemote_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_LsRemote_Call) RunAndReturn(run func(string) (string, error)) *Client_LsRemote_Call {
_c.Call.Return(run)
return _c
}
// RemoveContents provides a mock function with no fields
func (_m *Client) RemoveContents() (string, error) {
ret := _m.Called()
@ -400,6 +803,33 @@ func (_m *Client) RemoveContents() (string, error) {
return r0, r1
}
// Client_RemoveContents_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveContents'
type Client_RemoveContents_Call struct {
*mock.Call
}
// RemoveContents is a helper method to define mock.On call
func (_e *Client_Expecter) RemoveContents() *Client_RemoveContents_Call {
return &Client_RemoveContents_Call{Call: _e.mock.On("RemoveContents")}
}
func (_c *Client_RemoveContents_Call) Run(run func()) *Client_RemoveContents_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_RemoveContents_Call) Return(_a0 string, _a1 error) *Client_RemoveContents_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_RemoveContents_Call) RunAndReturn(run func() (string, error)) *Client_RemoveContents_Call {
_c.Call.Return(run)
return _c
}
// RevisionMetadata provides a mock function with given fields: revision
func (_m *Client) RevisionMetadata(revision string) (*git.RevisionMetadata, error) {
ret := _m.Called(revision)
@ -430,6 +860,34 @@ func (_m *Client) RevisionMetadata(revision string) (*git.RevisionMetadata, erro
return r0, r1
}
// Client_RevisionMetadata_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RevisionMetadata'
type Client_RevisionMetadata_Call struct {
*mock.Call
}
// RevisionMetadata is a helper method to define mock.On call
// - revision string
func (_e *Client_Expecter) RevisionMetadata(revision interface{}) *Client_RevisionMetadata_Call {
return &Client_RevisionMetadata_Call{Call: _e.mock.On("RevisionMetadata", revision)}
}
func (_c *Client_RevisionMetadata_Call) Run(run func(revision string)) *Client_RevisionMetadata_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_RevisionMetadata_Call) Return(_a0 *git.RevisionMetadata, _a1 error) *Client_RevisionMetadata_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_RevisionMetadata_Call) RunAndReturn(run func(string) (*git.RevisionMetadata, error)) *Client_RevisionMetadata_Call {
_c.Call.Return(run)
return _c
}
// Root provides a mock function with no fields
func (_m *Client) Root() string {
ret := _m.Called()
@ -448,6 +906,33 @@ func (_m *Client) Root() string {
return r0
}
// Client_Root_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Root'
type Client_Root_Call struct {
*mock.Call
}
// Root is a helper method to define mock.On call
func (_e *Client_Expecter) Root() *Client_Root_Call {
return &Client_Root_Call{Call: _e.mock.On("Root")}
}
func (_c *Client_Root_Call) Run(run func()) *Client_Root_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_Root_Call) Return(_a0 string) *Client_Root_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_Root_Call) RunAndReturn(run func() string) *Client_Root_Call {
_c.Call.Return(run)
return _c
}
// SetAuthor provides a mock function with given fields: name, email
func (_m *Client) SetAuthor(name string, email string) (string, error) {
ret := _m.Called(name, email)
@ -476,6 +961,35 @@ func (_m *Client) SetAuthor(name string, email string) (string, error) {
return r0, r1
}
// Client_SetAuthor_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetAuthor'
type Client_SetAuthor_Call struct {
*mock.Call
}
// SetAuthor is a helper method to define mock.On call
// - name string
// - email string
func (_e *Client_Expecter) SetAuthor(name interface{}, email interface{}) *Client_SetAuthor_Call {
return &Client_SetAuthor_Call{Call: _e.mock.On("SetAuthor", name, email)}
}
func (_c *Client_SetAuthor_Call) Run(run func(name string, email string)) *Client_SetAuthor_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *Client_SetAuthor_Call) Return(_a0 string, _a1 error) *Client_SetAuthor_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_SetAuthor_Call) RunAndReturn(run func(string, string) (string, error)) *Client_SetAuthor_Call {
_c.Call.Return(run)
return _c
}
// Submodule provides a mock function with no fields
func (_m *Client) Submodule() error {
ret := _m.Called()
@ -494,6 +1008,33 @@ func (_m *Client) Submodule() error {
return r0
}
// Client_Submodule_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Submodule'
type Client_Submodule_Call struct {
*mock.Call
}
// Submodule is a helper method to define mock.On call
func (_e *Client_Expecter) Submodule() *Client_Submodule_Call {
return &Client_Submodule_Call{Call: _e.mock.On("Submodule")}
}
func (_c *Client_Submodule_Call) Run(run func()) *Client_Submodule_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_Submodule_Call) Return(_a0 error) *Client_Submodule_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_Submodule_Call) RunAndReturn(run func() error) *Client_Submodule_Call {
_c.Call.Return(run)
return _c
}
// VerifyCommitSignature provides a mock function with given fields: _a0
func (_m *Client) VerifyCommitSignature(_a0 string) (string, error) {
ret := _m.Called(_a0)
@ -522,6 +1063,34 @@ func (_m *Client) VerifyCommitSignature(_a0 string) (string, error) {
return r0, r1
}
// Client_VerifyCommitSignature_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'VerifyCommitSignature'
type Client_VerifyCommitSignature_Call struct {
*mock.Call
}
// VerifyCommitSignature is a helper method to define mock.On call
// - _a0 string
func (_e *Client_Expecter) VerifyCommitSignature(_a0 interface{}) *Client_VerifyCommitSignature_Call {
return &Client_VerifyCommitSignature_Call{Call: _e.mock.On("VerifyCommitSignature", _a0)}
}
func (_c *Client_VerifyCommitSignature_Call) Run(run func(_a0 string)) *Client_VerifyCommitSignature_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *Client_VerifyCommitSignature_Call) Return(_a0 string, _a1 error) *Client_VerifyCommitSignature_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_VerifyCommitSignature_Call) RunAndReturn(run func(string) (string, error)) *Client_VerifyCommitSignature_Call {
_c.Call.Return(run)
return _c
}
// NewClient creates a new instance of Client. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -14,6 +14,14 @@ type Client struct {
mock.Mock
}
type Client_Expecter struct {
mock *mock.Mock
}
func (_m *Client) EXPECT() *Client_Expecter {
return &Client_Expecter{mock: &_m.Mock}
}
// CleanChartCache provides a mock function with given fields: chart, version
func (_m *Client) CleanChartCache(chart string, version string) error {
ret := _m.Called(chart, version)
@ -32,6 +40,35 @@ func (_m *Client) CleanChartCache(chart string, version string) error {
return r0
}
// Client_CleanChartCache_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CleanChartCache'
type Client_CleanChartCache_Call struct {
*mock.Call
}
// CleanChartCache is a helper method to define mock.On call
// - chart string
// - version string
func (_e *Client_Expecter) CleanChartCache(chart interface{}, version interface{}) *Client_CleanChartCache_Call {
return &Client_CleanChartCache_Call{Call: _e.mock.On("CleanChartCache", chart, version)}
}
func (_c *Client_CleanChartCache_Call) Run(run func(chart string, version string)) *Client_CleanChartCache_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *Client_CleanChartCache_Call) Return(_a0 error) *Client_CleanChartCache_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *Client_CleanChartCache_Call) RunAndReturn(run func(string, string) error) *Client_CleanChartCache_Call {
_c.Call.Return(run)
return _c
}
// ExtractChart provides a mock function with given fields: chart, version, passCredentials, manifestMaxExtractedSize, disableManifestMaxExtractedSize
func (_m *Client) ExtractChart(chart string, version string, passCredentials bool, manifestMaxExtractedSize int64, disableManifestMaxExtractedSize bool) (string, io.Closer, error) {
ret := _m.Called(chart, version, passCredentials, manifestMaxExtractedSize, disableManifestMaxExtractedSize)
@ -69,6 +106,38 @@ func (_m *Client) ExtractChart(chart string, version string, passCredentials boo
return r0, r1, r2
}
// Client_ExtractChart_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExtractChart'
type Client_ExtractChart_Call struct {
*mock.Call
}
// ExtractChart is a helper method to define mock.On call
// - chart string
// - version string
// - passCredentials bool
// - manifestMaxExtractedSize int64
// - disableManifestMaxExtractedSize bool
func (_e *Client_Expecter) ExtractChart(chart interface{}, version interface{}, passCredentials interface{}, manifestMaxExtractedSize interface{}, disableManifestMaxExtractedSize interface{}) *Client_ExtractChart_Call {
return &Client_ExtractChart_Call{Call: _e.mock.On("ExtractChart", chart, version, passCredentials, manifestMaxExtractedSize, disableManifestMaxExtractedSize)}
}
func (_c *Client_ExtractChart_Call) Run(run func(chart string, version string, passCredentials bool, manifestMaxExtractedSize int64, disableManifestMaxExtractedSize bool)) *Client_ExtractChart_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string), args[2].(bool), args[3].(int64), args[4].(bool))
})
return _c
}
func (_c *Client_ExtractChart_Call) Return(_a0 string, _a1 io.Closer, _a2 error) *Client_ExtractChart_Call {
_c.Call.Return(_a0, _a1, _a2)
return _c
}
func (_c *Client_ExtractChart_Call) RunAndReturn(run func(string, string, bool, int64, bool) (string, io.Closer, error)) *Client_ExtractChart_Call {
_c.Call.Return(run)
return _c
}
// GetIndex provides a mock function with given fields: noCache, maxIndexSize
func (_m *Client) GetIndex(noCache bool, maxIndexSize int64) (*helm.Index, error) {
ret := _m.Called(noCache, maxIndexSize)
@ -99,6 +168,35 @@ func (_m *Client) GetIndex(noCache bool, maxIndexSize int64) (*helm.Index, error
return r0, r1
}
// Client_GetIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetIndex'
type Client_GetIndex_Call struct {
*mock.Call
}
// GetIndex is a helper method to define mock.On call
// - noCache bool
// - maxIndexSize int64
func (_e *Client_Expecter) GetIndex(noCache interface{}, maxIndexSize interface{}) *Client_GetIndex_Call {
return &Client_GetIndex_Call{Call: _e.mock.On("GetIndex", noCache, maxIndexSize)}
}
func (_c *Client_GetIndex_Call) Run(run func(noCache bool, maxIndexSize int64)) *Client_GetIndex_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(bool), args[1].(int64))
})
return _c
}
func (_c *Client_GetIndex_Call) Return(_a0 *helm.Index, _a1 error) *Client_GetIndex_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_GetIndex_Call) RunAndReturn(run func(bool, int64) (*helm.Index, error)) *Client_GetIndex_Call {
_c.Call.Return(run)
return _c
}
// GetTags provides a mock function with given fields: chart, noCache
func (_m *Client) GetTags(chart string, noCache bool) ([]string, error) {
ret := _m.Called(chart, noCache)
@ -129,6 +227,35 @@ func (_m *Client) GetTags(chart string, noCache bool) ([]string, error) {
return r0, r1
}
// Client_GetTags_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTags'
type Client_GetTags_Call struct {
*mock.Call
}
// GetTags is a helper method to define mock.On call
// - chart string
// - noCache bool
func (_e *Client_Expecter) GetTags(chart interface{}, noCache interface{}) *Client_GetTags_Call {
return &Client_GetTags_Call{Call: _e.mock.On("GetTags", chart, noCache)}
}
func (_c *Client_GetTags_Call) Run(run func(chart string, noCache bool)) *Client_GetTags_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(bool))
})
return _c
}
func (_c *Client_GetTags_Call) Return(_a0 []string, _a1 error) *Client_GetTags_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_GetTags_Call) RunAndReturn(run func(string, bool) ([]string, error)) *Client_GetTags_Call {
_c.Call.Return(run)
return _c
}
// TestHelmOCI provides a mock function with no fields
func (_m *Client) TestHelmOCI() (bool, error) {
ret := _m.Called()
@ -157,6 +284,33 @@ func (_m *Client) TestHelmOCI() (bool, error) {
return r0, r1
}
// Client_TestHelmOCI_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TestHelmOCI'
type Client_TestHelmOCI_Call struct {
*mock.Call
}
// TestHelmOCI is a helper method to define mock.On call
func (_e *Client_Expecter) TestHelmOCI() *Client_TestHelmOCI_Call {
return &Client_TestHelmOCI_Call{Call: _e.mock.On("TestHelmOCI")}
}
func (_c *Client_TestHelmOCI_Call) Run(run func()) *Client_TestHelmOCI_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *Client_TestHelmOCI_Call) Return(_a0 bool, _a1 error) *Client_TestHelmOCI_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Client_TestHelmOCI_Call) RunAndReturn(run func() (bool, error)) *Client_TestHelmOCI_Call {
_c.Call.Return(run)
return _c
}
// NewClient creates a new instance of Client. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewClient(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -9,11 +9,48 @@ type TempPaths struct {
mock.Mock
}
type TempPaths_Expecter struct {
mock *mock.Mock
}
func (_m *TempPaths) EXPECT() *TempPaths_Expecter {
return &TempPaths_Expecter{mock: &_m.Mock}
}
// Add provides a mock function with given fields: key, value
func (_m *TempPaths) Add(key string, value string) {
_m.Called(key, value)
}
// TempPaths_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'
type TempPaths_Add_Call struct {
*mock.Call
}
// Add is a helper method to define mock.On call
// - key string
// - value string
func (_e *TempPaths_Expecter) Add(key interface{}, value interface{}) *TempPaths_Add_Call {
return &TempPaths_Add_Call{Call: _e.mock.On("Add", key, value)}
}
func (_c *TempPaths_Add_Call) Run(run func(key string, value string)) *TempPaths_Add_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string), args[1].(string))
})
return _c
}
func (_c *TempPaths_Add_Call) Return() *TempPaths_Add_Call {
_c.Call.Return()
return _c
}
func (_c *TempPaths_Add_Call) RunAndReturn(run func(string, string)) *TempPaths_Add_Call {
_c.Run(run)
return _c
}
// GetPath provides a mock function with given fields: key
func (_m *TempPaths) GetPath(key string) (string, error) {
ret := _m.Called(key)
@ -42,6 +79,34 @@ func (_m *TempPaths) GetPath(key string) (string, error) {
return r0, r1
}
// TempPaths_GetPath_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPath'
type TempPaths_GetPath_Call struct {
*mock.Call
}
// GetPath is a helper method to define mock.On call
// - key string
func (_e *TempPaths_Expecter) GetPath(key interface{}) *TempPaths_GetPath_Call {
return &TempPaths_GetPath_Call{Call: _e.mock.On("GetPath", key)}
}
func (_c *TempPaths_GetPath_Call) Run(run func(key string)) *TempPaths_GetPath_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *TempPaths_GetPath_Call) Return(_a0 string, _a1 error) *TempPaths_GetPath_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *TempPaths_GetPath_Call) RunAndReturn(run func(string) (string, error)) *TempPaths_GetPath_Call {
_c.Call.Return(run)
return _c
}
// GetPathIfExists provides a mock function with given fields: key
func (_m *TempPaths) GetPathIfExists(key string) string {
ret := _m.Called(key)
@ -60,6 +125,34 @@ func (_m *TempPaths) GetPathIfExists(key string) string {
return r0
}
// TempPaths_GetPathIfExists_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPathIfExists'
type TempPaths_GetPathIfExists_Call struct {
*mock.Call
}
// GetPathIfExists is a helper method to define mock.On call
// - key string
func (_e *TempPaths_Expecter) GetPathIfExists(key interface{}) *TempPaths_GetPathIfExists_Call {
return &TempPaths_GetPathIfExists_Call{Call: _e.mock.On("GetPathIfExists", key)}
}
func (_c *TempPaths_GetPathIfExists_Call) Run(run func(key string)) *TempPaths_GetPathIfExists_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *TempPaths_GetPathIfExists_Call) Return(_a0 string) *TempPaths_GetPathIfExists_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *TempPaths_GetPathIfExists_Call) RunAndReturn(run func(string) string) *TempPaths_GetPathIfExists_Call {
_c.Call.Return(run)
return _c
}
// GetPaths provides a mock function with no fields
func (_m *TempPaths) GetPaths() map[string]string {
ret := _m.Called()
@ -80,6 +173,33 @@ func (_m *TempPaths) GetPaths() map[string]string {
return r0
}
// TempPaths_GetPaths_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPaths'
type TempPaths_GetPaths_Call struct {
*mock.Call
}
// GetPaths is a helper method to define mock.On call
func (_e *TempPaths_Expecter) GetPaths() *TempPaths_GetPaths_Call {
return &TempPaths_GetPaths_Call{Call: _e.mock.On("GetPaths")}
}
func (_c *TempPaths_GetPaths_Call) Run(run func()) *TempPaths_GetPaths_Call {
_c.Call.Run(func(args mock.Arguments) {
run()
})
return _c
}
func (_c *TempPaths_GetPaths_Call) Return(_a0 map[string]string) *TempPaths_GetPaths_Call {
_c.Call.Return(_a0)
return _c
}
func (_c *TempPaths_GetPaths_Call) RunAndReturn(run func() map[string]string) *TempPaths_GetPaths_Call {
_c.Call.Return(run)
return _c
}
// NewTempPaths creates a new instance of TempPaths. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewTempPaths(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -17,6 +17,14 @@ type Service struct {
mock.Mock
}
type Service_Expecter struct {
mock *mock.Mock
}
func (_m *Service) EXPECT() *Service_Expecter {
return &Service_Expecter{mock: &_m.Mock}
}
// GetAppDetails provides a mock function with given fields: ctx, app
func (_m *Service) GetAppDetails(ctx context.Context, app *v1alpha1.Application) (*shared.AppDetail, error) {
ret := _m.Called(ctx, app)
@ -47,6 +55,35 @@ func (_m *Service) GetAppDetails(ctx context.Context, app *v1alpha1.Application)
return r0, r1
}
// Service_GetAppDetails_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAppDetails'
type Service_GetAppDetails_Call struct {
*mock.Call
}
// GetAppDetails is a helper method to define mock.On call
// - ctx context.Context
// - app *v1alpha1.Application
func (_e *Service_Expecter) GetAppDetails(ctx interface{}, app interface{}) *Service_GetAppDetails_Call {
return &Service_GetAppDetails_Call{Call: _e.mock.On("GetAppDetails", ctx, app)}
}
func (_c *Service_GetAppDetails_Call) Run(run func(ctx context.Context, app *v1alpha1.Application)) *Service_GetAppDetails_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(*v1alpha1.Application))
})
return _c
}
func (_c *Service_GetAppDetails_Call) Return(_a0 *shared.AppDetail, _a1 error) *Service_GetAppDetails_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Service_GetAppDetails_Call) RunAndReturn(run func(context.Context, *v1alpha1.Application) (*shared.AppDetail, error)) *Service_GetAppDetails_Call {
_c.Call.Return(run)
return _c
}
// GetCommitMetadata provides a mock function with given fields: ctx, repoURL, commitSHA, project
func (_m *Service) GetCommitMetadata(ctx context.Context, repoURL string, commitSHA string, project string) (*shared.CommitMetadata, error) {
ret := _m.Called(ctx, repoURL, commitSHA, project)
@ -77,6 +114,37 @@ func (_m *Service) GetCommitMetadata(ctx context.Context, repoURL string, commit
return r0, r1
}
// Service_GetCommitMetadata_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCommitMetadata'
type Service_GetCommitMetadata_Call struct {
*mock.Call
}
// GetCommitMetadata is a helper method to define mock.On call
// - ctx context.Context
// - repoURL string
// - commitSHA string
// - project string
func (_e *Service_Expecter) GetCommitMetadata(ctx interface{}, repoURL interface{}, commitSHA interface{}, project interface{}) *Service_GetCommitMetadata_Call {
return &Service_GetCommitMetadata_Call{Call: _e.mock.On("GetCommitMetadata", ctx, repoURL, commitSHA, project)}
}
func (_c *Service_GetCommitMetadata_Call) Run(run func(ctx context.Context, repoURL string, commitSHA string, project string)) *Service_GetCommitMetadata_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(context.Context), args[1].(string), args[2].(string), args[3].(string))
})
return _c
}
func (_c *Service_GetCommitMetadata_Call) Return(_a0 *shared.CommitMetadata, _a1 error) *Service_GetCommitMetadata_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *Service_GetCommitMetadata_Call) RunAndReturn(run func(context.Context, string, string, string) (*shared.CommitMetadata, error)) *Service_GetCommitMetadata_Call {
_c.Call.Return(run)
return _c
}
// NewService creates a new instance of Service. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewService(t interface {

View file

@ -1,4 +1,4 @@
// Code generated by mockery v2.52.4. DO NOT EDIT.
// Code generated by mockery. DO NOT EDIT.
package mocks
@ -9,6 +9,14 @@ type TokenProvider struct {
mock.Mock
}
type TokenProvider_Expecter struct {
mock *mock.Mock
}
func (_m *TokenProvider) EXPECT() *TokenProvider_Expecter {
return &TokenProvider_Expecter{mock: &_m.Mock}
}
// GetToken provides a mock function with given fields: scope
func (_m *TokenProvider) GetToken(scope string) (string, error) {
ret := _m.Called(scope)
@ -37,6 +45,34 @@ func (_m *TokenProvider) GetToken(scope string) (string, error) {
return r0, r1
}
// TokenProvider_GetToken_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetToken'
type TokenProvider_GetToken_Call struct {
*mock.Call
}
// GetToken is a helper method to define mock.On call
// - scope string
func (_e *TokenProvider_Expecter) GetToken(scope interface{}) *TokenProvider_GetToken_Call {
return &TokenProvider_GetToken_Call{Call: _e.mock.On("GetToken", scope)}
}
func (_c *TokenProvider_GetToken_Call) Run(run func(scope string)) *TokenProvider_GetToken_Call {
_c.Call.Run(func(args mock.Arguments) {
run(args[0].(string))
})
return _c
}
func (_c *TokenProvider_GetToken_Call) Return(_a0 string, _a1 error) *TokenProvider_GetToken_Call {
_c.Call.Return(_a0, _a1)
return _c
}
func (_c *TokenProvider_GetToken_Call) RunAndReturn(run func(string) (string, error)) *TokenProvider_GetToken_Call {
_c.Call.Return(run)
return _c
}
// NewTokenProvider creates a new instance of TokenProvider. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
// The first argument is typically a *testing.T value.
func NewTokenProvider(t interface {