Skip to content

Commit 08de04b

Browse files
committed
Change test expectations due to exception change
1 parent b9a5c92 commit 08de04b

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

tests/ImageSharp.Tests/Formats/Bmp/BmpDecoderTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public void BmpDecoder_DegenerateMemoryRequest_ShouldTranslateTo_ImageFormatExce
7777
where TPixel : unmanaged, IPixel<TPixel>
7878
{
7979
provider.LimitAllocatorBufferCapacity().InPixelsSqrt(10);
80-
ImageFormatException ex = Assert.Throws<ImageFormatException>(() => provider.GetImage(BmpDecoder));
80+
InvalidImageContentException ex = Assert.Throws<InvalidImageContentException>(() => provider.GetImage(BmpDecoder));
8181
Assert.IsType<InvalidMemoryOperationException>(ex.InnerException);
8282
}
8383

tests/ImageSharp.Tests/Formats/Gif/GifDecoderTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ public void GifDecoder_DegenerateMemoryRequest_ShouldTranslateTo_ImageFormatExce
179179
where TPixel : unmanaged, IPixel<TPixel>
180180
{
181181
provider.LimitAllocatorBufferCapacity().InPixelsSqrt(10);
182-
ImageFormatException ex = Assert.Throws<ImageFormatException>(() => provider.GetImage(GifDecoder));
182+
InvalidImageContentException ex = Assert.Throws<InvalidImageContentException>(() => provider.GetImage(GifDecoder));
183183
Assert.IsType<InvalidMemoryOperationException>(ex.InnerException);
184184
}
185185

tests/ImageSharp.Tests/Formats/Jpg/JpegDecoderTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ public void DegenerateMemoryRequest_ShouldTranslateTo_ImageFormatException<TPixe
107107
where TPixel : unmanaged, IPixel<TPixel>
108108
{
109109
provider.LimitAllocatorBufferCapacity().InBytesSqrt(10);
110-
ImageFormatException ex = Assert.Throws<ImageFormatException>(() => provider.GetImage(JpegDecoder));
110+
InvalidImageContentException ex = Assert.Throws<InvalidImageContentException>(() => provider.GetImage(JpegDecoder));
111111
this.Output.WriteLine(ex.Message);
112112
Assert.IsType<InvalidMemoryOperationException>(ex.InnerException);
113113
}

tests/ImageSharp.Tests/Formats/Png/PngDecoderTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ public void PngDecoder_DegenerateMemoryRequest_ShouldTranslateTo_ImageFormatExce
397397
where TPixel : unmanaged, IPixel<TPixel>
398398
{
399399
provider.LimitAllocatorBufferCapacity().InPixelsSqrt(10);
400-
ImageFormatException ex = Assert.Throws<ImageFormatException>(() => provider.GetImage(PngDecoder));
400+
InvalidImageContentException ex = Assert.Throws<InvalidImageContentException>(() => provider.GetImage(PngDecoder));
401401
Assert.IsType<InvalidMemoryOperationException>(ex.InnerException);
402402
}
403403

tests/ImageSharp.Tests/Formats/Tga/TgaDecoderTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -740,7 +740,7 @@ public void TgaDecoder_DegenerateMemoryRequest_ShouldTranslateTo_ImageFormatExce
740740
where TPixel : unmanaged, IPixel<TPixel>
741741
{
742742
provider.LimitAllocatorBufferCapacity().InPixelsSqrt(10);
743-
ImageFormatException ex = Assert.Throws<ImageFormatException>(() => provider.GetImage(TgaDecoder));
743+
InvalidImageContentException ex = Assert.Throws<InvalidImageContentException>(() => provider.GetImage(TgaDecoder));
744744
Assert.IsType<InvalidMemoryOperationException>(ex.InnerException);
745745
}
746746

0 commit comments

Comments
 (0)