Skip to content

Commit f2983c6

Browse files
committed
Remove useless lambda block.
1 parent 26cd2c8 commit f2983c6

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/test/java/org/apache/commons/imaging/formats/webp/WebPReadTest.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,8 @@ class WebPReadTest extends AbstractWebPTest {
5050
void testBufferedImageNotSupported() throws IOException {
5151
final File emptyWebP = new File(WebPReadTest.class.getResource("/images/webp/empty/empty-100x100.webp").getFile());
5252
final WebPImageParser parser = new WebPImageParser();
53-
final ImagingException exception = assertThrows(ImagingException.class, () -> {
54-
parser.getBufferedImage(ByteSource.file(emptyWebP), parser.getDefaultParameters());
55-
});
53+
final ImagingException exception = assertThrows(ImagingException.class,
54+
() -> parser.getBufferedImage(ByteSource.file(emptyWebP), parser.getDefaultParameters()));
5655
assertTrue(exception.getMessage().contains("Reading WebP files is currently not supported"));
5756
}
5857

@@ -91,9 +90,7 @@ void testRead(final File imageFile) throws Exception {
9190
*/
9291
@Test
9392
void testWebPChunkInvalidSizeBytes() {
94-
final ImagingException exception = assertThrows(ImagingException.class, () -> {
95-
new WebPChunkIccp(0, 10, new byte[] {});
96-
});
93+
final ImagingException exception = assertThrows(ImagingException.class, () -> new WebPChunkIccp(0, 10, new byte[] {}));
9794
assertEquals("Chunk size must match bytes length", exception.getMessage());
9895
}
9996
}

0 commit comments

Comments
 (0)