Issue #2161: unify test input locations

This commit is contained in:
rnveach 2015-10-12 12:04:06 -04:00 committed by Roman Ivanov
parent d69581b3d0
commit e36b1959ca
2 changed files with 8 additions and 3 deletions

View File

@ -23,6 +23,7 @@ import static com.puppycrawl.tools.checkstyle.checks.design.InnerTypeLastCheck.M
import static org.junit.Assert.assertArrayEquals;
import java.io.File;
import java.io.IOException;
import org.junit.Test;
@ -31,6 +32,11 @@ import com.puppycrawl.tools.checkstyle.DefaultConfiguration;
import com.puppycrawl.tools.checkstyle.api.TokenTypes;
public class InnerTypeLastCheckTest extends BaseCheckTestSupport {
@Override
protected String getPath(String filename) throws IOException {
return super.getPath("checks" + File.separator
+ "design" + File.separator + filename);
}
@Test
public void testGetRequiredTokens() {
@ -50,8 +56,7 @@ public class InnerTypeLastCheckTest extends BaseCheckTestSupport {
"78:5: " + getCheckMessage(MSG_KEY),
"95:9: " + getCheckMessage(MSG_KEY),
};
verify(checkConfig, getPath("design" + File.separator
+ "InputInnerClassCheck.java"), expected);
verify(checkConfig, getPath("InputInnerClassCheck.java"), expected);
}
@Test

View File

@ -1,4 +1,4 @@
package com.puppycrawl.tools.checkstyle.design;
package com.puppycrawl.tools.checkstyle.checks.design;
public class InputInnerClassCheck {
public int test1 = 100;