// // Copyright (c) James Jackson-South and contributors. // Licensed under the Apache License, Version 2.0. // namespace ImageSharp.Tests { using System.Collections.Generic; /// /// The test base class for reading and writing to files. /// public abstract class FileTestBase : TestBase { /// /// A collection made up of one file for each image format /// public static IEnumerable DefaultFiles = new[] { TestImages.Bmp.Car, TestImages.Jpeg.Baseline.Calliphora, TestImages.Png.Splash, TestImages.Gif.Trans }; /// /// A collection of all the bmp test images /// public static IEnumerable AllBmpFiles = TestImages.Bmp.All; /// /// A collection of all the jpeg test images /// public static IEnumerable AllJpegFiles = TestImages.Jpeg.All; /// /// A collection of all the png test images /// public static IEnumerable AllPngFiles = TestImages.Png.All; /// /// A collection of all the gif test images /// public static IEnumerable AllGifFiles = TestImages.Gif.All; /// /// The standard pixel format enumeration /// public const PixelTypes StandardPixelType = PixelTypes.StandardImageClass; public static class Extensions { public const string Bmp = "bmp"; public const string Jpeg = "jpg"; public const string Png = "png"; public const string Gif = "gif"; } /// /// The collection of image files to test against. /// protected static readonly List Files = new List { TestFile.Create(TestImages.Jpeg.Baseline.Calliphora), // TestFile.Create(TestImages.Jpeg.Baseline.Turtle), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Baseline.Ycck), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Baseline.Cmyk), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Baseline.Floorplan), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Baseline.Bad.MissingEOF), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Progressive.Fb), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Progressive.Progress), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Baseline.GammaDalaiLamaGray), // Perf: Enable for local testing only // TestFile.Create(TestImages.Jpeg.Progressive.Bad.BadEOF), // Perf: Enable for local testing only TestFile.Create(TestImages.Bmp.Car), // TestFile.Create(TestImages.Bmp.NegHeight), // Perf: Enable for local testing only TestFile.Create(TestImages.Png.Splash), // TestFile.Create(TestImages.Png.Cross), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.ChunkLength1), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.ChunkLength2), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Powerpoint), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Blur), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Indexed), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.SplashInterlaced), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Interlaced), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Filter0), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Filter1), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Filter2), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Filter3), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Filter4), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.FilterVar), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.P1), // Perf: Enable for local testing only // TestFile.Create(TestImages.Png.Pd), // Perf: Enable for local testing only TestFile.Create(TestImages.Gif.Rings), // TestFile.Create(TestImages.Gif.Trans), // Perf: Enable for local testing only // TestFile.Create(TestImages.Gif.Cheers), // Perf: Enable for local testing only // TestFile.Create(TestImages.Gif.Giphy) // Perf: Enable for local testing only }; } }