diff --git a/assertj-core/src/main/java/org/assertj/core/api/Assertions.java b/assertj-core/src/main/java/org/assertj/core/api/Assertions.java index ff790fefaa..2e9c655961 100644 --- a/assertj-core/src/main/java/org/assertj/core/api/Assertions.java +++ b/assertj-core/src/main/java/org/assertj/core/api/Assertions.java @@ -1477,6 +1477,7 @@ public static THROWABLE catchThrowableOfType(Class ThrowingCallable shouldRaiseThrowable) { return ThrowableAssert.catchThrowableOfType(type, shouldRaiseThrowable); } + /** * Allows catching an instance of {@link Exception}. *

diff --git a/assertj-core/src/main/java/org/assertj/core/api/AssertionsForClassTypes.java b/assertj-core/src/main/java/org/assertj/core/api/AssertionsForClassTypes.java index bdf2d8f8d5..eb7c8eb446 100644 --- a/assertj-core/src/main/java/org/assertj/core/api/AssertionsForClassTypes.java +++ b/assertj-core/src/main/java/org/assertj/core/api/AssertionsForClassTypes.java @@ -822,7 +822,7 @@ public static ThrowableTypeAssert assertThatExceptionOf *

assertThatNoException().isThrownBy(() -> { System.out.println("OK"); });
* * This method is more or less the same of {@code assertThatCode(...).doesNotThrowAnyException();} but in a more natural way. - + * * @return the created {@link NotThrownAssert}. * @since 3.17.0 */ diff --git a/assertj-core/src/main/java/org/assertj/core/api/ThrowableAssert.java b/assertj-core/src/main/java/org/assertj/core/api/ThrowableAssert.java index fc5677dbd0..40e02f432f 100644 --- a/assertj-core/src/main/java/org/assertj/core/api/ThrowableAssert.java +++ b/assertj-core/src/main/java/org/assertj/core/api/ThrowableAssert.java @@ -80,7 +80,7 @@ public static THROWABLE catchThrowableOfType(Class if (throwable == null) return null; // check exception type new ThrowableAssert<>(throwable).overridingErrorMessage(shouldBeInstance(throwable, type).create()) - .isInstanceOf(type); + .isInstanceOf(type); return (THROWABLE) throwable; }