github.com/kyma-incubator/compass/components/director@v0.0.0-20230623144113-d764f56ff805/internal/domain/application/automock/bundle_service.go (about) 1 // Code generated by mockery. DO NOT EDIT. 2 3 package automock 4 5 import ( 6 context "context" 7 8 model "github.com/kyma-incubator/compass/components/director/internal/model" 9 mock "github.com/stretchr/testify/mock" 10 11 resource "github.com/kyma-incubator/compass/components/director/pkg/resource" 12 ) 13 14 // BundleService is an autogenerated mock type for the BundleService type 15 type BundleService struct { 16 mock.Mock 17 } 18 19 // CreateMultiple provides a mock function with given fields: ctx, resourceType, resourceID, in 20 func (_m *BundleService) CreateMultiple(ctx context.Context, resourceType resource.Type, resourceID string, in []*model.BundleCreateInput) error { 21 ret := _m.Called(ctx, resourceType, resourceID, in) 22 23 var r0 error 24 if rf, ok := ret.Get(0).(func(context.Context, resource.Type, string, []*model.BundleCreateInput) error); ok { 25 r0 = rf(ctx, resourceType, resourceID, in) 26 } else { 27 r0 = ret.Error(0) 28 } 29 30 return r0 31 } 32 33 // GetForApplication provides a mock function with given fields: ctx, id, applicationID 34 func (_m *BundleService) GetForApplication(ctx context.Context, id string, applicationID string) (*model.Bundle, error) { 35 ret := _m.Called(ctx, id, applicationID) 36 37 var r0 *model.Bundle 38 if rf, ok := ret.Get(0).(func(context.Context, string, string) *model.Bundle); ok { 39 r0 = rf(ctx, id, applicationID) 40 } else { 41 if ret.Get(0) != nil { 42 r0 = ret.Get(0).(*model.Bundle) 43 } 44 } 45 46 var r1 error 47 if rf, ok := ret.Get(1).(func(context.Context, string, string) error); ok { 48 r1 = rf(ctx, id, applicationID) 49 } else { 50 r1 = ret.Error(1) 51 } 52 53 return r0, r1 54 } 55 56 // ListByApplicationIDs provides a mock function with given fields: ctx, applicationIDs, pageSize, cursor 57 func (_m *BundleService) ListByApplicationIDs(ctx context.Context, applicationIDs []string, pageSize int, cursor string) ([]*model.BundlePage, error) { 58 ret := _m.Called(ctx, applicationIDs, pageSize, cursor) 59 60 var r0 []*model.BundlePage 61 if rf, ok := ret.Get(0).(func(context.Context, []string, int, string) []*model.BundlePage); ok { 62 r0 = rf(ctx, applicationIDs, pageSize, cursor) 63 } else { 64 if ret.Get(0) != nil { 65 r0 = ret.Get(0).([]*model.BundlePage) 66 } 67 } 68 69 var r1 error 70 if rf, ok := ret.Get(1).(func(context.Context, []string, int, string) error); ok { 71 r1 = rf(ctx, applicationIDs, pageSize, cursor) 72 } else { 73 r1 = ret.Error(1) 74 } 75 76 return r0, r1 77 } 78 79 type mockConstructorTestingTNewBundleService interface { 80 mock.TestingT 81 Cleanup(func()) 82 } 83 84 // NewBundleService creates a new instance of BundleService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 85 func NewBundleService(t mockConstructorTestingTNewBundleService) *BundleService { 86 mock := &BundleService{} 87 mock.Mock.Test(t) 88 89 t.Cleanup(func() { mock.AssertExpectations(t) }) 90 91 return mock 92 }