diff --git a/src/test/java/com/puppycrawl/tools/checkstyle/MainTest.java b/src/test/java/com/puppycrawl/tools/checkstyle/MainTest.java index 71b7c6423..62c8c0e08 100644 --- a/src/test/java/com/puppycrawl/tools/checkstyle/MainTest.java +++ b/src/test/java/com/puppycrawl/tools/checkstyle/MainTest.java @@ -435,8 +435,6 @@ public class MainTest { @Test public void testCreateListener_IllegalStateException() throws Exception { - Class[] param = new Class[1]; - param[0] = File.class; Method method = Main.class.getDeclaredMethod("createListener", String.class, String.class); method.setAccessible(true); try { @@ -454,8 +452,6 @@ public class MainTest { @Test public void testCreateListenerWithLocation_IllegalStateException() throws Exception { - Class[] param = new Class[1]; - param[0] = File.class; Method method = Main.class.getDeclaredMethod("createListener", String.class, String.class); method.setAccessible(true); String outDir = "myfolder123"; @@ -509,8 +505,6 @@ public class MainTest { @Test @SuppressWarnings("unchecked") public void testListFiles_notFile() throws Exception { - Class[] param = new Class[1]; - param[0] = File.class; Method method = Main.class.getDeclaredMethod("listFiles", File.class); method.setAccessible(true); @@ -526,8 +520,6 @@ public class MainTest { @Test @SuppressWarnings("unchecked") public void testListFiles_DirectoryWithNull() throws Exception { - Class[] param = new Class[1]; - param[0] = File.class; Method method = Main.class.getDeclaredMethod("listFiles", File.class); method.setAccessible(true);