File tree Expand file tree Collapse file tree 5 files changed +5
-5
lines changed
tests/ImageSharp.Tests/Formats Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Original file line number Diff line number Diff 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
Original file line number Diff line number Diff 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
Original file line number Diff line number Diff 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 }
Original file line number Diff line number Diff 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
Original file line number Diff line number Diff 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
You can’t perform that action at this time.
0 commit comments