mirror of https://github.com/SixLabors/ImageSharp
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
1.3 KiB
38 lines
1.3 KiB
namespace ImageSharp.Tests
|
|
{
|
|
using System;
|
|
|
|
using Xunit;
|
|
|
|
public class JpegDecoderTests : TestBase
|
|
{
|
|
public static string[] BaselineTestJpegs =
|
|
{
|
|
TestImages.Jpeg.Baseline.Calliphora, TestImages.Jpeg.Baseline.Cmyk,
|
|
TestImages.Jpeg.Baseline.Jpeg400, TestImages.Jpeg.Baseline.Jpeg444
|
|
};
|
|
|
|
public static string[] ProgressiveTestJpegs = TestImages.Jpeg.Progressive.All;
|
|
|
|
[Theory]
|
|
[WithFileCollection(nameof(BaselineTestJpegs), PixelTypes.Color | PixelTypes.StandardImageClass | PixelTypes.Argb)]
|
|
public void OpenBaselineJpeg_SaveBmp<TColor>(TestImageProvider<TColor> provider)
|
|
where TColor : struct, IPackedPixel, IEquatable<TColor>
|
|
{
|
|
Image<TColor> image = provider.GetImage();
|
|
|
|
provider.Utility.SaveTestOutputFile(image, "bmp");
|
|
}
|
|
|
|
[Theory]
|
|
[WithFileCollection(nameof(ProgressiveTestJpegs), PixelTypes.Color | PixelTypes.StandardImageClass | PixelTypes.Argb)]
|
|
public void OpenProgressiveJpeg_SaveBmp<TColor>(TestImageProvider<TColor> provider)
|
|
where TColor : struct, IPackedPixel, IEquatable<TColor>
|
|
{
|
|
Image<TColor> image = provider.GetImage();
|
|
|
|
provider.Utility.SaveTestOutputFile(image, "bmp");
|
|
}
|
|
|
|
}
|
|
}
|