github.com/kyma-incubator/compass/components/director@v0.0.0-20230623144113-d764f56ff805/internal/domain/integrationsystem/automock/integration_system_service.go (about) 1 // Code generated by mockery. DO NOT EDIT. 2 3 package automock 4 5 import ( 6 context "context" 7 8 mock "github.com/stretchr/testify/mock" 9 10 model "github.com/kyma-incubator/compass/components/director/internal/model" 11 ) 12 13 // IntegrationSystemService is an autogenerated mock type for the IntegrationSystemService type 14 type IntegrationSystemService struct { 15 mock.Mock 16 } 17 18 // Create provides a mock function with given fields: ctx, in 19 func (_m *IntegrationSystemService) Create(ctx context.Context, in model.IntegrationSystemInput) (string, error) { 20 ret := _m.Called(ctx, in) 21 22 var r0 string 23 if rf, ok := ret.Get(0).(func(context.Context, model.IntegrationSystemInput) string); ok { 24 r0 = rf(ctx, in) 25 } else { 26 r0 = ret.Get(0).(string) 27 } 28 29 var r1 error 30 if rf, ok := ret.Get(1).(func(context.Context, model.IntegrationSystemInput) error); ok { 31 r1 = rf(ctx, in) 32 } else { 33 r1 = ret.Error(1) 34 } 35 36 return r0, r1 37 } 38 39 // Delete provides a mock function with given fields: ctx, id 40 func (_m *IntegrationSystemService) Delete(ctx context.Context, id string) error { 41 ret := _m.Called(ctx, id) 42 43 var r0 error 44 if rf, ok := ret.Get(0).(func(context.Context, string) error); ok { 45 r0 = rf(ctx, id) 46 } else { 47 r0 = ret.Error(0) 48 } 49 50 return r0 51 } 52 53 // Get provides a mock function with given fields: ctx, id 54 func (_m *IntegrationSystemService) Get(ctx context.Context, id string) (*model.IntegrationSystem, error) { 55 ret := _m.Called(ctx, id) 56 57 var r0 *model.IntegrationSystem 58 if rf, ok := ret.Get(0).(func(context.Context, string) *model.IntegrationSystem); ok { 59 r0 = rf(ctx, id) 60 } else { 61 if ret.Get(0) != nil { 62 r0 = ret.Get(0).(*model.IntegrationSystem) 63 } 64 } 65 66 var r1 error 67 if rf, ok := ret.Get(1).(func(context.Context, string) error); ok { 68 r1 = rf(ctx, id) 69 } else { 70 r1 = ret.Error(1) 71 } 72 73 return r0, r1 74 } 75 76 // List provides a mock function with given fields: ctx, pageSize, cursor 77 func (_m *IntegrationSystemService) List(ctx context.Context, pageSize int, cursor string) (model.IntegrationSystemPage, error) { 78 ret := _m.Called(ctx, pageSize, cursor) 79 80 var r0 model.IntegrationSystemPage 81 if rf, ok := ret.Get(0).(func(context.Context, int, string) model.IntegrationSystemPage); ok { 82 r0 = rf(ctx, pageSize, cursor) 83 } else { 84 r0 = ret.Get(0).(model.IntegrationSystemPage) 85 } 86 87 var r1 error 88 if rf, ok := ret.Get(1).(func(context.Context, int, string) error); ok { 89 r1 = rf(ctx, pageSize, cursor) 90 } else { 91 r1 = ret.Error(1) 92 } 93 94 return r0, r1 95 } 96 97 // Update provides a mock function with given fields: ctx, id, in 98 func (_m *IntegrationSystemService) Update(ctx context.Context, id string, in model.IntegrationSystemInput) error { 99 ret := _m.Called(ctx, id, in) 100 101 var r0 error 102 if rf, ok := ret.Get(0).(func(context.Context, string, model.IntegrationSystemInput) error); ok { 103 r0 = rf(ctx, id, in) 104 } else { 105 r0 = ret.Error(0) 106 } 107 108 return r0 109 } 110 111 type mockConstructorTestingTNewIntegrationSystemService interface { 112 mock.TestingT 113 Cleanup(func()) 114 } 115 116 // NewIntegrationSystemService creates a new instance of IntegrationSystemService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 117 func NewIntegrationSystemService(t mockConstructorTestingTNewIntegrationSystemService) *IntegrationSystemService { 118 mock := &IntegrationSystemService{} 119 mock.Mock.Test(t) 120 121 t.Cleanup(func() { mock.AssertExpectations(t) }) 122 123 return mock 124 }