public async Task<Guid> SaveFileDataAsync(byte[] bytes, string contentType, string fileName)
        {
            var fileBlobEntity = new FileBlob(bytes, contentType, fileName);

            _unitOfWork.Repository<FileBlob>().Add(fileBlobEntity);

            await _unitOfWork.SaveChanges();

            _loggingService.Info(string.Format("Saved file {0} to persistence store", fileName));

            return fileBlobEntity.BlobGuid;
        }
        public async Task GetFileDataAsyncCallsCorrectUnitOfWorkMethodTest()
        {
            var entity = new FileBlob();

            var mockUnitOfWork = new Mock<IUnitOfWork>();
            var mockLoggerService = new Mock<ILoggerService>();

            mockUnitOfWork.Setup(x => x.Repository<FileBlob>().GetAsync(It.IsAny<Expression<Func<FileBlob, bool>>>()))
                .Returns(() => Task.FromResult(entity));

            var persistenceService = new FilesPersistenceService(mockUnitOfWork.Object, mockLoggerService.Object);

            await persistenceService.GetFileDataAsync(It.IsAny<Guid>());
            mockUnitOfWork.Verify(m => m.Repository<FileBlob>().GetAsync(It.IsAny<Expression<Func<FileBlob, bool>>>()), Times.Once);
        }