namespace System.Drawing.Imaging.Tests
{
- // Disposing any ImageAttributes seems to cause a crash on Unix.
- [ActiveIssue(20884, TestPlatforms.AnyUnix)]
public class ImageAttributesTests
{
private readonly Rectangle _rectangle = new Rectangle(0, 0, 64, 64);
imageAttr.Dispose();
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)] // Causes a crash on libgdiplus.
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void Clone_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetThreshold_Threshold_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_TestData))]
public void SetThreshold_ThresholdType_Success(ColorAdjustType type)
}
}
- [ConditionalTheory(Helpers.GdiplusIsAvailable)]
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[MemberData(nameof(ColorAdjustTypeI_TestData))]
public void SetThreshold_ThresholdTypeI_Success(ColorAdjustType type)
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetThreshold_Disposed_ThrowsArgumentException()
{
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.SetThreshold(0.5f));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void SetThreshold_InvalidType_ThrowsArgumentException(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_AllTypesAllowed_TestData))]
public void ClearThreshold_ThresholdTypeI_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearThreshold_Disposed_ThrowsArgumentException()
{
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.ClearThreshold(ColorAdjustType.Default));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void ClearThreshold_InvalidTypes_ThrowsArgumentException(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetGamma_Gamma_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_TestData))]
public void SetGamma_GammaType_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustTypeI_TestData))]
public void SetGamma_GammaTypeI_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetNoOp_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_AllTypesAllowed_TestData))]
public void SetNoOp_Type_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_TestData))]
public void ClearNoOp_Type_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearNoOp_Disposed_ThrowsArgumentException()
{
yield return new object[] { ColorChannelFlag.ColorChannelY, Color.FromArgb(255, 100, 100, 100), Color.FromArgb(255, 207, 207, 207) };
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(SetOutputChannel_ColorChannelFlag_TestData))]
public void SetOutputChannel_Flag_Success(ColorChannelFlag flag, Color actualColor, Color expectedColor)
yield return new object[] { ColorChannelFlag.ColorChannelY, ColorAdjustType.Bitmap, Color.FromArgb(255, 100, 100, 100), Color.FromArgb(255, 207, 207, 207) };
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(SetOutputChannel_ColorChannelFlagType_TestData))]
public void SetOutputChannel_FlagType_Success(ColorChannelFlag flag, ColorAdjustType type, Color actualColor, Color expectedColor)
yield return new object[] { ColorChannelFlag.ColorChannelY, ColorAdjustType.Text, Color.FromArgb(255, 100, 100, 100) };
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(SetOutputChannel_ColorChannelFlagTypeI_TestData))]
public void SetOutputChannel_FlagTypeI_Success(ColorChannelFlag flag, ColorAdjustType type, Color color)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetOutputChannel_Disposed_ThrowsArgumentException()
{
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.SetOutputChannel(ColorChannelFlag.ColorChannelY, ColorAdjustType.Default));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void SetOutputChannel_InvalidTypes_ThrowsArgumentException(ColorAdjustType type)
yield return new object[] { (ColorChannelFlag)int.MaxValue };
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(SetOutputChannel_InvalidColorChannelFlags_TestData))]
public void SetOutputChannel_InvalidFlags_ThrowsArgumentException(ColorChannelFlag flag)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearOutputChannel_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_AllTypesAllowed_TestData))]
public void ClearOutputChannel_Type_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearOutputChannel_Disposed_ThrowsArgumentException()
{
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.ClearOutputChannel(ColorAdjustType.Default));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void ClearOutputChannel_InvalidTypes_ThrowsArgumentException(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetOutputChannelColorProfile_Name_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetOutputChannelColorProfile_Disposed_ThrowsArgumentException()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetOutputChannelColorProfile_InvalidPath_ThrowsOutOfMemoryException()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetOutputChannelColorProfile_InvalidPath_ThrowsPathTooLongException()
{
}
}
-
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void SetOutputChannelColorProfile_InvalidTypes_ThrowsArgumentException(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearOutputChannelColorProfile_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_AllTypesAllowed_TestData))]
public void ClearOutputChannelColorProfile_Type_Success(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearOutputChannelColorProfile_Disposed_ThrowsArgumentException()
{
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.ClearOutputChannelColorProfile(ColorAdjustType.Default));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void ClearOutputChannelColorProfile_InvalidTypes_ThrowsArgumentException(ColorAdjustType type)
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void SetRemapTable_EmptyMap_ThrowsArgumentException()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void ClearRemapTable_Success()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_AllTypesAllowed_TestData))]
public void ClearRemapTable_Type_Success(ColorAdjustType type)
AssertExtensions.Throws<ArgumentException>(null, () => imageAttr.SetWrapMode(WrapMode.Clamp, Color.Black, true));
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalFact(Helpers.GdiplusIsAvailable)]
public void GetAdjustedPalette_Disposed_ThrowsArgumentException()
{
}
}
+ [ActiveIssue(20884, TestPlatforms.AnyUnix)]
[ConditionalTheory(Helpers.GdiplusIsAvailable)]
[MemberData(nameof(ColorAdjustType_InvalidTypes_TestData))]
public void GetAdjustedPalette_Disposed_ThrowsArgumentException(ColorAdjustType type)