Skip to content

Commit

Permalink
Issue #4437: Modified AvoidStarImportCheckTest.java and moved its inp…
Browse files Browse the repository at this point in the history
…ut files to the avoidstarimport subdirectory
  • Loading branch information
Subbu Dantu authored and rnveach committed Jun 9, 2017
1 parent 1056372 commit d0719e1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Expand Up @@ -36,7 +36,7 @@ public class AvoidStarImportCheckTest
@Override
protected String getPath(String filename) throws IOException {
return super.getPath("checks" + File.separator
+ "imports" + File.separator + filename);
+ "imports" + File.separator + "avoidstarimport" + File.separator + filename);
}

@Test
Expand All @@ -53,7 +53,7 @@ public void testDefaultOperation()
"28: " + getCheckMessage(MSG_KEY, "java.io.File.*"),
};

verify(checkConfig, getPath("InputAvoidStarImport.java"),
verify(checkConfig, getPath("InputAvoidStarImportDefault.java"),
expected);
}

Expand All @@ -69,7 +69,7 @@ public void testExcludes()
"7: " + getCheckMessage(MSG_KEY, "com.puppycrawl.tools.checkstyle.checks.imports.*"),
"28: " + getCheckMessage(MSG_KEY, "java.io.File.*"),
};
verify(checkConfig, getPath("InputAvoidStarImport.java"),
verify(checkConfig, getPath("InputAvoidStarImportDefault.java"),
expected2);
}

Expand All @@ -82,7 +82,7 @@ public void testAllowClassImports() throws Exception {
"25: " + getCheckMessage(MSG_KEY, "javax.swing.WindowConstants.*"),
"26: " + getCheckMessage(MSG_KEY, "javax.swing.WindowConstants.*"),
"28: " + getCheckMessage(MSG_KEY, "java.io.File.*"), };
verify(checkConfig, getPath("InputAvoidStarImport.java"), expected2);
verify(checkConfig, getPath("InputAvoidStarImportDefault.java"), expected2);
}

@Test
Expand All @@ -95,7 +95,7 @@ public void testAllowStaticMemberImports() throws Exception {
"9: " + getCheckMessage(MSG_KEY, "java.io.*"),
"10: " + getCheckMessage(MSG_KEY, "java.lang.*"),
};
verify(checkConfig, getPath("InputAvoidStarImport.java"), expected2);
verify(checkConfig, getPath("InputAvoidStarImportDefault.java"), expected2);
}

@Test
Expand Down
Expand Up @@ -2,7 +2,7 @@
// Test case file for checkstyle.
// Created: 2001
////////////////////////////////////////////////////////////////////////////////
package com.puppycrawl.tools.checkstyle.checks.imports;
package com.puppycrawl.tools.checkstyle.checks.imports.avoidstarimport;

import com.puppycrawl.tools.checkstyle.checks.imports.*;

Expand Down Expand Up @@ -53,7 +53,7 @@
* @author Michael Studman
* @see Calendar Should avoid unused import for Calendar
**/
class InputAvoidStarImport
class InputAvoidStarImportDefault
{
/** ignore **/
private Class mUse1 = Connection.class;
Expand Down

0 comments on commit d0719e1

Please sign in to comment.