diff --git a/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/TypeNameCheckTest.java b/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/TypeNameCheckTest.java index c7fd4a891..e3790d357 100644 --- a/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/TypeNameCheckTest.java +++ b/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/TypeNameCheckTest.java @@ -26,6 +26,7 @@ import java.io.File; import java.io.IOException; import org.apache.commons.lang3.ArrayUtils; +import org.junit.Before; import org.junit.Test; import com.puppycrawl.tools.checkstyle.BaseCheckTestSupport; @@ -36,11 +37,11 @@ import com.puppycrawl.tools.checkstyle.utils.TokenUtils; public class TypeNameCheckTest extends BaseCheckTestSupport { - private final String inputFilename; + private String inputFilename; - public TypeNameCheckTest() throws IOException { - inputFilename = getPath("naming" + File.separator - + "InputTypeName.java"); + @Before + public void setUp() throws IOException { + inputFilename = getPath("naming" + File.separator + "InputTypeName.java"); } @Test