// Code generated by mockery; DO NOT EDIT. // github.com/vektra/mockery // template: testify package mocks import ( "context" "github.com/bnema/gordon/internal/boundaries/out" mock "github.com/stretchr/testify/mock" ) // NewMockSecretFileStore creates a new instance of MockSecretFileStore. 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 NewMockSecretFileStore(t interface { mock.TestingT Cleanup(func()) }) *MockSecretFileStore { if helper, ok := t.(interface{ Helper() }); ok { helper.Helper() } mock := &MockSecretFileStore{} mock.Mock.Test(t) t.Cleanup(func() { if helper, ok := t.(interface{ Helper() }); ok { helper.Helper() } mock.AssertExpectations(t) }) return mock } // MockSecretFileStore is an autogenerated mock type for the SecretFileStore type type MockSecretFileStore struct { mock.Mock } type MockSecretFileStore_Expecter struct { mock *mock.Mock } func (_m *MockSecretFileStore) EXPECT() *MockSecretFileStore_Expecter { return &MockSecretFileStore_Expecter{mock: &_m.Mock} } // List provides a mock function for the type MockSecretFileStore func (_mock *MockSecretFileStore) List(ctx context.Context) ([]out.SecretFileSet, error) { ret := _mock.Called(ctx) if len(ret) == 0 { panic("no return value specified for List") } var r0 []out.SecretFileSet var r1 error if returnFunc, ok := ret.Get(0).(func(context.Context) ([]out.SecretFileSet, error)); ok { return returnFunc(ctx) } if returnFunc, ok := ret.Get(0).(func(context.Context) []out.SecretFileSet); ok { r0 = returnFunc(ctx) } else { if ret.Get(0) != nil { r0 = ret.Get(0).([]out.SecretFileSet) } } if returnFunc, ok := ret.Get(1).(func(context.Context) error); ok { r1 = returnFunc(ctx) } else { r1 = ret.Error(1) } return r0, r1 } // MockSecretFileStore_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List' type MockSecretFileStore_List_Call struct { *mock.Call } // List is a helper method to define mock.On call // - ctx context.Context func (_e *MockSecretFileStore_Expecter) List(ctx any) *MockSecretFileStore_List_Call { return &MockSecretFileStore_List_Call{Call: _e.mock.On("List", ctx)} } func (_c *MockSecretFileStore_List_Call) Run(run func(ctx context.Context)) *MockSecretFileStore_List_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 context.Context if args[0] != nil { arg0 = args[0].(context.Context) } run( arg0, ) }) return _c } func (_c *MockSecretFileStore_List_Call) Return(secretFileSets []out.SecretFileSet, err error) *MockSecretFileStore_List_Call { _c.Call.Return(secretFileSets, err) return _c } func (_c *MockSecretFileStore_List_Call) RunAndReturn(run func(ctx context.Context) ([]out.SecretFileSet, error)) *MockSecretFileStore_List_Call { _c.Call.Return(run) return _c } // Read provides a mock function for the type MockSecretFileStore func (_mock *MockSecretFileStore) Read(ctx context.Context, app string, container string, key string) (string, error) { ret := _mock.Called(ctx, app, container, key) if len(ret) == 0 { panic("no return value specified for Read") } var r0 string var r1 error if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, string) (string, error)); ok { return returnFunc(ctx, app, container, key) } if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, string) string); ok { r0 = returnFunc(ctx, app, container, key) } else { r0 = ret.Get(0).(string) } if returnFunc, ok := ret.Get(1).(func(context.Context, string, string, string) error); ok { r1 = returnFunc(ctx, app, container, key) } else { r1 = ret.Error(1) } return r0, r1 } // MockSecretFileStore_Read_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Read' type MockSecretFileStore_Read_Call struct { *mock.Call } // Read is a helper method to define mock.On call // - ctx context.Context // - app string // - container string // - key string func (_e *MockSecretFileStore_Expecter) Read(ctx any, app any, container any, key any) *MockSecretFileStore_Read_Call { return &MockSecretFileStore_Read_Call{Call: _e.mock.On("Read", ctx, app, container, key)} } func (_c *MockSecretFileStore_Read_Call) Run(run func(ctx context.Context, app string, container string, key string)) *MockSecretFileStore_Read_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 context.Context if args[0] != nil { arg0 = args[0].(context.Context) } var arg1 string if args[1] != nil { arg1 = args[1].(string) } var arg2 string if args[2] != nil { arg2 = args[2].(string) } var arg3 string if args[3] != nil { arg3 = args[3].(string) } run( arg0, arg1, arg2, arg3, ) }) return _c } func (_c *MockSecretFileStore_Read_Call) Return(s string, err error) *MockSecretFileStore_Read_Call { _c.Call.Return(s, err) return _c } func (_c *MockSecretFileStore_Read_Call) RunAndReturn(run func(ctx context.Context, app string, container string, key string) (string, error)) *MockSecretFileStore_Read_Call { _c.Call.Return(run) return _c } // Remove provides a mock function for the type MockSecretFileStore func (_mock *MockSecretFileStore) Remove(ctx context.Context, app string, container string) error { ret := _mock.Called(ctx, app, container) if len(ret) == 0 { panic("no return value specified for Remove") } var r0 error if returnFunc, ok := ret.Get(0).(func(context.Context, string, string) error); ok { r0 = returnFunc(ctx, app, container) } else { r0 = ret.Error(0) } return r0 } // MockSecretFileStore_Remove_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Remove' type MockSecretFileStore_Remove_Call struct { *mock.Call } // Remove is a helper method to define mock.On call // - ctx context.Context // - app string // - container string func (_e *MockSecretFileStore_Expecter) Remove(ctx any, app any, container any) *MockSecretFileStore_Remove_Call { return &MockSecretFileStore_Remove_Call{Call: _e.mock.On("Remove", ctx, app, container)} } func (_c *MockSecretFileStore_Remove_Call) Run(run func(ctx context.Context, app string, container string)) *MockSecretFileStore_Remove_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 context.Context if args[0] != nil { arg0 = args[0].(context.Context) } var arg1 string if args[1] != nil { arg1 = args[1].(string) } var arg2 string if args[2] != nil { arg2 = args[2].(string) } run( arg0, arg1, arg2, ) }) return _c } func (_c *MockSecretFileStore_Remove_Call) Return(err error) *MockSecretFileStore_Remove_Call { _c.Call.Return(err) return _c } func (_c *MockSecretFileStore_Remove_Call) RunAndReturn(run func(ctx context.Context, app string, container string) error) *MockSecretFileStore_Remove_Call { _c.Call.Return(run) return _c } // Write provides a mock function for the type MockSecretFileStore func (_mock *MockSecretFileStore) Write(ctx context.Context, app string, container string, values map[string]string) (map[string]string, error) { ret := _mock.Called(ctx, app, container, values) if len(ret) == 0 { panic("no return value specified for Write") } var r0 map[string]string var r1 error if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, map[string]string) (map[string]string, error)); ok { return returnFunc(ctx, app, container, values) } if returnFunc, ok := ret.Get(0).(func(context.Context, string, string, map[string]string) map[string]string); ok { r0 = returnFunc(ctx, app, container, values) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(map[string]string) } } if returnFunc, ok := ret.Get(1).(func(context.Context, string, string, map[string]string) error); ok { r1 = returnFunc(ctx, app, container, values) } else { r1 = ret.Error(1) } return r0, r1 } // MockSecretFileStore_Write_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Write' type MockSecretFileStore_Write_Call struct { *mock.Call } // Write is a helper method to define mock.On call // - ctx context.Context // - app string // - container string // - values map[string]string func (_e *MockSecretFileStore_Expecter) Write(ctx any, app any, container any, values any) *MockSecretFileStore_Write_Call { return &MockSecretFileStore_Write_Call{Call: _e.mock.On("Write", ctx, app, container, values)} } func (_c *MockSecretFileStore_Write_Call) Run(run func(ctx context.Context, app string, container string, values map[string]string)) *MockSecretFileStore_Write_Call { _c.Call.Run(func(args mock.Arguments) { var arg0 context.Context if args[0] != nil { arg0 = args[0].(context.Context) } var arg1 string if args[1] != nil { arg1 = args[1].(string) } var arg2 string if args[2] != nil { arg2 = args[2].(string) } var arg3 map[string]string if args[3] != nil { arg3 = args[3].(map[string]string) } run( arg0, arg1, arg2, arg3, ) }) return _c } func (_c *MockSecretFileStore_Write_Call) Return(stringToString map[string]string, err error) *MockSecretFileStore_Write_Call { _c.Call.Return(stringToString, err) return _c } func (_c *MockSecretFileStore_Write_Call) RunAndReturn(run func(ctx context.Context, app string, container string, values map[string]string) (map[string]string, error)) *MockSecretFileStore_Write_Call { _c.Call.Return(run) return _c }