From beddaf450158fd81bf0da9400efb5e1d25eedba9 Mon Sep 17 00:00:00 2001 From: Marc Philipp Date: Sun, 11 Oct 2020 13:12:01 +0200 Subject: [PATCH] Remove unnecessary throws clause --- .../platform/commons/support/ReflectionSupportTests.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/platform-tests/src/test/java/org/junit/platform/commons/support/ReflectionSupportTests.java b/platform-tests/src/test/java/org/junit/platform/commons/support/ReflectionSupportTests.java index 2938b258f553..8262a31b7a07 100644 --- a/platform-tests/src/test/java/org/junit/platform/commons/support/ReflectionSupportTests.java +++ b/platform-tests/src/test/java/org/junit/platform/commons/support/ReflectionSupportTests.java @@ -224,7 +224,7 @@ void tryToReadFieldValuePreconditions() throws Exception { } @Test - void findMethodDelegates() throws Exception { + void findMethodDelegates() { assertEquals(ReflectionUtils.findMethod(Boolean.class, "valueOf", String.class.getName()), ReflectionSupport.findMethod(Boolean.class, "valueOf", String.class.getName())); @@ -233,7 +233,7 @@ void findMethodDelegates() throws Exception { } @Test - void findMethodPreconditions() throws Exception { + void findMethodPreconditions() { assertPreconditionViolationException("Class", () -> ReflectionSupport.findMethod(null, "valueOf", String.class.getName())); assertPreconditionViolationExceptionForString("Method name", @@ -280,13 +280,13 @@ void findMethodsPreconditions() { } @Test - void findNestedClassesDelegates() throws Exception { + void findNestedClassesDelegates() { assertEquals(ReflectionUtils.findNestedClasses(ClassWithNestedClasses.class, ReflectionUtils::isStatic), ReflectionSupport.findNestedClasses(ClassWithNestedClasses.class, ReflectionUtils::isStatic)); } @Test - void findNestedClassesPreconditions() throws Exception { + void findNestedClassesPreconditions() { assertPreconditionViolationException("Class", () -> ReflectionSupport.findNestedClasses(null, ReflectionUtils::isStatic)); assertPreconditionViolationException("Predicate",