Reformat JUnit 5 examples

This commit is contained in:
David Morley
2016-05-23 06:14:18 -05:00
parent 4bc347acca
commit e641ca0598
4 changed files with 6 additions and 11 deletions
@@ -2,8 +2,6 @@ package com.baeldung;
import org.junit.gen5.api.Test;
import java.util.ArrayList;
import static org.junit.gen5.api.Assertions.assertEquals;
import static org.junit.gen5.api.Assertions.expectThrows;
@@ -12,7 +10,9 @@ public class ExceptionTest {
@Test
void shouldThrowException() {
Throwable exception = expectThrows(UnsupportedOperationException.class,
() -> {throw new UnsupportedOperationException("Not supported");});
() -> {
throw new UnsupportedOperationException("Not supported");
});
assertEquals(exception.getMessage(), "Not supported");
}
}