// Code generated by mockery. DO NOT EDIT. package mocks import ( "context" "io" "mime/multipart" "github.com/harness/gitness/registry/app/storage" "github.com/harness/gitness/registry/types" "github.com/stretchr/testify/mock" ) // FileManager is a mock type for filemanager.FileManager type FileManager struct { mock.Mock } // UploadFile provides a mock function func (m *FileManager) UploadFile(ctx context.Context, filePath string, regName string, regID int64, rootParentID int64, rootIdentifier string, file multipart.File, fileReader io.Reader, filename string) (types.FileInfo, error) { args := m.Called(ctx, filePath, regName, regID, rootParentID, rootIdentifier, file, fileReader, filename) return args.Get(0).(types.FileInfo), args.Error(1) } // DownloadFile provides a mock function func (m *FileManager) DownloadFile(ctx context.Context, filePath string, regInfo types.Registry, rootIdentifier string) (*storage.FileReader, int64, string, error) { args := m.Called(ctx, filePath, regInfo, rootIdentifier) return args.Get(0).(*storage.FileReader), args.Get(1).(int64), args.Get(2).(string), args.Error(3) } // DeleteFile provides a mock function func (m *FileManager) DeleteFile(ctx context.Context, filePath string, regID int) error { args := m.Called(ctx, filePath, regID) return args.Error(0) } // HeadFile provides a mock function func (m *FileManager) HeadFile(ctx context.Context, filePath string, regID int64) (string, error) { args := m.Called(ctx, filePath, regID) return args.String(0), args.Error(1) } // GetFileMetadata provides a mock function func (m *FileManager) GetFileMetadata(ctx context.Context, filePath string, regID int64) (types.FileInfo, error) { args := m.Called(ctx, filePath, regID) return args.Get(0).(types.FileInfo), args.Error(1) } // DeleteFileByRegistryID provides a mock function func (m *FileManager) DeleteFileByRegistryID(ctx context.Context, regID int64, regName string) error { args := m.Called(ctx, regID, regName) return args.Error(0) } // GetFilesMetadata provides a mock function func (m *FileManager) GetFilesMetadata(ctx context.Context, filePath string, regID int64, sortByField string, sortByOrder string, limit int, offset int, search string) (*[]types.FileNodeMetadata, error) { args := m.Called(ctx, filePath, regID, sortByField, sortByOrder, limit, offset, search) return args.Get(0).(*[]types.FileNodeMetadata), args.Error(1) } // CountFilesByPath provides a mock function func (m *FileManager) CountFilesByPath(ctx context.Context, filePath string, regID int64) (int64, error) { args := m.Called(ctx, filePath, regID) return args.Get(0).(int64), args.Error(1) }