public PreviewController(
     ThrottlingOptions throttlingOptions,
     RawFileStorageInfoProvider rawFileStorageInfoProvider,
     IObjectsStorageReader objectsStorageReader,
     ImagePreviewService imagePreviewService)
 {
     _retryAfter = throttlingOptions.RetryAfter;
     _rawFileStorageInfoProvider = rawFileStorageInfoProvider;
     _objectsStorageReader       = objectsStorageReader;
     _imagePreviewService        = imagePreviewService;
 }
        public void CreatePreviewImage_Png()
        {
            // arrange
            var stream  = GetImageResourceStream("png.png");
            var service = new ImagePreviewService();

            // act
            var result = service.CreatePreviewImage(stream);
            var image  = Image.Load(result, out var imageFormat);

            // assert
            Assert.Equal(new Size(150, 150), image.Size());
            Assert.Equal(ImageFormats.Jpeg, imageFormat);
        }