kubelatte-ce
Форк от sbertech/kubelatte-ce
203 строки · 5.8 Кб
1// Code generated by mockery v2.20.0. DO NOT EDIT.
2
3package mocks4
5import (6context "context"7"gitverse.ru/ktrntrsv/kubelatte-ce/pkg/api/v1alpha1"8
9mock "github.com/stretchr/testify/mock"10v1 "k8s.io/apimachinery/pkg/apis/meta/v1"11
12watch "k8s.io/apimachinery/pkg/watch"13)
14
15// TemplateInterface is an autogenerated mock type for the TemplateInterface type
16type TemplateInterface struct {17mock.Mock18}
19
20// Create provides a mock function with given fields: ctx, template
21func (_m *TemplateInterface) Create(ctx context.Context, template *v1alpha1.Template) (*v1alpha1.Template, error) {22ret := _m.Called(ctx, template)23
24var r0 *v1alpha1.Template25var r1 error26if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template) (*v1alpha1.Template, error)); ok {27return rf(ctx, template)28}29if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template) *v1alpha1.Template); ok {30r0 = rf(ctx, template)31} else {32if ret.Get(0) != nil {33r0 = ret.Get(0).(*v1alpha1.Template)34}35}36
37if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template) error); ok {38r1 = rf(ctx, template)39} else {40r1 = ret.Error(1)41}42
43return r0, r144}
45
46// Delete provides a mock function with given fields: ctx, name, opts
47func (_m *TemplateInterface) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error {48ret := _m.Called(ctx, name, opts)49
50var r0 error51if rf, ok := ret.Get(0).(func(context.Context, string, v1.DeleteOptions) error); ok {52r0 = rf(ctx, name, opts)53} else {54r0 = ret.Error(0)55}56
57return r058}
59
60// Get provides a mock function with given fields: ctx, name, options
61func (_m *TemplateInterface) Get(ctx context.Context, name string, options v1.GetOptions) (*v1alpha1.Template, error) {62ret := _m.Called(ctx, name, options)63
64var r0 *v1alpha1.Template65var r1 error66if rf, ok := ret.Get(0).(func(context.Context, string, v1.GetOptions) (*v1alpha1.Template, error)); ok {67return rf(ctx, name, options)68}69if rf, ok := ret.Get(0).(func(context.Context, string, v1.GetOptions) *v1alpha1.Template); ok {70r0 = rf(ctx, name, options)71} else {72if ret.Get(0) != nil {73r0 = ret.Get(0).(*v1alpha1.Template)74}75}76
77if rf, ok := ret.Get(1).(func(context.Context, string, v1.GetOptions) error); ok {78r1 = rf(ctx, name, options)79} else {80r1 = ret.Error(1)81}82
83return r0, r184}
85
86// List provides a mock function with given fields: ctx, opts
87func (_m *TemplateInterface) List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.TemplateList, error) {88ret := _m.Called(ctx, opts)89
90var r0 *v1alpha1.TemplateList91var r1 error92if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) (*v1alpha1.TemplateList, error)); ok {93return rf(ctx, opts)94}95if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) *v1alpha1.TemplateList); ok {96r0 = rf(ctx, opts)97} else {98if ret.Get(0) != nil {99r0 = ret.Get(0).(*v1alpha1.TemplateList)100}101}102
103if rf, ok := ret.Get(1).(func(context.Context, v1.ListOptions) error); ok {104r1 = rf(ctx, opts)105} else {106r1 = ret.Error(1)107}108
109return r0, r1110}
111
112// Update provides a mock function with given fields: ctx, template, opts
113func (_m *TemplateInterface) Update(ctx context.Context, template *v1alpha1.Template, opts v1.UpdateOptions) (*v1alpha1.Template, error) {114ret := _m.Called(ctx, template, opts)115
116var r0 *v1alpha1.Template117var r1 error118if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) (*v1alpha1.Template, error)); ok {119return rf(ctx, template, opts)120}121if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) *v1alpha1.Template); ok {122r0 = rf(ctx, template, opts)123} else {124if ret.Get(0) != nil {125r0 = ret.Get(0).(*v1alpha1.Template)126}127}128
129if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) error); ok {130r1 = rf(ctx, template, opts)131} else {132r1 = ret.Error(1)133}134
135return r0, r1136}
137
138// UpdateStatus provides a mock function with given fields: ctx, hostEntry, opts
139func (_m *TemplateInterface) UpdateStatus(ctx context.Context, hostEntry *v1alpha1.Template, opts v1.UpdateOptions) (*v1alpha1.Template, error) {140ret := _m.Called(ctx, hostEntry, opts)141
142var r0 *v1alpha1.Template143var r1 error144if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) (*v1alpha1.Template, error)); ok {145return rf(ctx, hostEntry, opts)146}147if rf, ok := ret.Get(0).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) *v1alpha1.Template); ok {148r0 = rf(ctx, hostEntry, opts)149} else {150if ret.Get(0) != nil {151r0 = ret.Get(0).(*v1alpha1.Template)152}153}154
155if rf, ok := ret.Get(1).(func(context.Context, *v1alpha1.Template, v1.UpdateOptions) error); ok {156r1 = rf(ctx, hostEntry, opts)157} else {158r1 = ret.Error(1)159}160
161return r0, r1162}
163
164// Watch provides a mock function with given fields: ctx, opts
165func (_m *TemplateInterface) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) {166ret := _m.Called(ctx, opts)167
168var r0 watch.Interface169var r1 error170if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) (watch.Interface, error)); ok {171return rf(ctx, opts)172}173if rf, ok := ret.Get(0).(func(context.Context, v1.ListOptions) watch.Interface); ok {174r0 = rf(ctx, opts)175} else {176if ret.Get(0) != nil {177r0 = ret.Get(0).(watch.Interface)178}179}180
181if rf, ok := ret.Get(1).(func(context.Context, v1.ListOptions) error); ok {182r1 = rf(ctx, opts)183} else {184r1 = ret.Error(1)185}186
187return r0, r1188}
189
190type mockConstructorTestingTNewTemplateInterface interface {191mock.TestingT192Cleanup(func())193}
194
195// NewTemplateInterface creates a new instance of TemplateInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
196func NewTemplateInterface(t mockConstructorTestingTNewTemplateInterface) *TemplateInterface {197mock := &TemplateInterface{}198mock.Mock.Test(t)199
200t.Cleanup(func() { mock.AssertExpectations(t) })201
202return mock203}
204