// // Copyright (c) James Jackson-South and contributors. // Licensed under the Apache License, Version 2.0. // namespace ImageSharp.Tests { using System; using ImageSharp.PixelFormats; /// /// Provides instances for parametric unit tests. /// /// The pixel format of the image public abstract partial class TestImageProvider where TPixel : struct, IPixel { private class LambdaProvider : TestImageProvider { private readonly Func, Image> creator; public LambdaProvider(Func, Image> creator) { this.creator = creator; } public override Image GetImage() => this.creator(this.Factory); } } }