-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
201 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,3 +33,6 @@ replay_pid* | |
|
||
# Apple MacOS hidden file | ||
.DS_Store | ||
|
||
# The regression test Groovy script | ||
diff.groovy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# List of GIT repositories to clone / pull for checking with Checkstyle | ||
# File format: REPO_NAME|[github|git|hg]|REPO_GIT_URL|[COMMIT_ID]|[EXCLUDE FOLDERS] | ||
# Please note that bash comments works in this file | ||
|
||
# Few projects that delivers set of unusual Java constructions that shall be correctly handled by AST visitor | ||
# 'InputAllEscapedUnicodeCharacters' must be skipped because it is too big and slows down JXR | ||
checkstyle|git|https://github.com/checkstyle/checkstyle.git|master|**/checkstyle/src/test/resources-noncompilable/**/*,**/InputAllEscapedUnicodeCharacters.java | ||
sevntu-checkstyle|git|https://github.com/sevntu-checkstyle/sevntu.checkstyle|master|| | ||
|
||
openjdk7|hg|http://hg.openjdk.java.net/jdk7/jdk7/jdk/||| | ||
openjdk8|hg|http://hg.openjdk.java.net/jdk8/jdk8/jdk/|default|**/test/tools/pack200/typeannos/TypeUseTarget.java | ||
#All details at checkstyle/checkstyle#3033: TypeUseTarget till checkstyle/checkstyle#3238 ; ModalDialogActivationTest till JDK-8166015 ; 'jxc/8073519/**' not compilable by design ; ', jhsdb/**' - checkstyle do not support unicode identifiers | ||
openjdk9|hg|http://hg.openjdk.java.net/jdk9/jdk9/jdk/|default|**/test/tools/pack200/typeannos/TypeUseTarget.java,**/test/java/awt/Focus/ModalDialogActivationTest/ModalDialogActivationTest.java,**/test/javax/xml/bind/jxc/8073519/**,**/test/sun/tools/jhsdb/** | ||
guava|git|https://github.com/google/guava|v18.0|| | ||
|
||
findbugs|git|https://github.com/findbugsproject/findbugs|3.0.1|| | ||
pmd|git|https://github.com/pmd/pmd|pmd_releases/5.3.0|**/pmd/pmd-java/src/test/**/* | ||
lombok-ast|git|https://github.com/rzwitserloot/lombok.ast|v0.2|**/lombok-ast/test/**/* | ||
|
||
spring-framework|git|https://github.com/spring-projects/spring-framework|v4.1.6.RELEASE|| | ||
hibernate-orm|git|https://github.com/hibernate/hibernate-orm|4.2.19.Final|**/hibernate-orm/documentation/**/* | ||
elasticsearch|git|https://github.com/elastic/elasticsearch|v1.5.2|| | ||
java-design-patterns|git|https://github.com/iluwatar/java-design-patterns|dd855a376bc025aa61f6816584f79eb9854fe5d7|| | ||
MaterialDesignLibrary|git|https://github.com/navasmdc/MaterialDesignLibrary|1.3|| | ||
Hbase|git|https://github.com/apache/hbase|1.1.0.1|| | ||
Orekit|git|https://github.com/CS-SI/Orekit|942785a5c79b5470baec3d41cab18f3adc78280e|| | ||
|
||
# Those projects are quite old and have lot of legacy code | ||
apache-ant|git|https://github.com/apache/ant|ANT_194|**/apache-ant/src/tests/**/*,**/apache-ant/src/etc/testcases/ | ||
apache-jsecurity|git|https://github.com/apache/jsecurity|c2ac5b90a467aedb04b52ae50a99e83207d847b3|| | ||
android-launcher|git|https://github.com/android/platform_packages_apps_launcher|android-2.1_r2.1p2|| | ||
apache-struts|git|https://github.com/apache/struts.git|master|**/apache-struts/**/resources/**/* | ||
|
||
# Projects which contain a lot of labmda expressions | ||
infinispan|git|https://github.com/infinispan/infinispan|7.2.5.Final|| | ||
protonpack|git|https://github.com/poetix/protonpack|protonpack-1.7|| | ||
jOOL|git|https://github.com/jOOQ/jOOL|version-0.9.7|| | ||
RxJava|git|https://github.com/ReactiveX/RxJava|v1.0.9|| | ||
|
||
# Few projects with excludes to decrease a number of checked files (usefull for some checks which specify overly strong code style policy) | ||
checkstyle-with-excludes|git|https://github.com/checkstyle/checkstyle.git|master|**/checkstyle-with-excludes/src/test/**/*,**/checkstyle-with-excludes/src/it/resources/**/*,**/resources-noncompilable/**/* | ||
sevntu-checkstyle-with-excludes|git|https://github.com/sevntu-checkstyle/sevntu.checkstyle|master|**/sevntu-checkstyle-with-excludes/sevntu-checks/src/test/**/* | ||
findbugs-with-excldues|git|https://github.com/findbugsproject/findbugs|3.0.1|**/findbugs-with-excldues/eclipsePlugin-test/**/*,**/findbugs-with-excldues/findbugsTestCases/**/*,**/findbugs-with-excldues/JSR305-testCases/**/*,**/findbugs-with-excldues/findbugsTestCasesOS/**/* | ||
hibernate-orm-with-excludes|git|https://github.com/hibernate/hibernate-orm|4.2.19.Final|**/hibernate-orm-with-excludes/documentation/**/*,**/hibernate-orm-with-excludes/**/src/test/**/* | ||
|
||
# Guava with excldues to generate reports only for those files which are not excluded in Guava's pom.xml for checkstyle-maven-plugin | ||
# See https://github.com/checkstyle/checkstyle/wiki/How-to-generate-Checkstyle-report-for-Google-Guava-project | ||
guava-mvnstyle|git|https://github.com/google/guava|master|**/guava-mvnstyle/**/test/**/*,**/guava-mvnstyle/guava-gwt/src-super/**/*,**/guava-mvnstyle/guava-gwt/test-super/**/*,**/guava-mvnstyle/guava-tests/**/* | ||
|
||
# custom javadoc tags | ||
nbia-dcm4che-tools|git|https://github.com/thprakash/nbia-dcm4che-tools|c3591e6f0f84827586db25abded6708e5386ef1a|| |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
src/main/java/com/github/checkstyle/regression/report/DiffGroovyWrapper.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
//////////////////////////////////////////////////////////////////////////////// | ||
// checkstyle: Checks Java source code for adherence to a set of rules. | ||
// Copyright (C) 2001-2017 the original author or authors. | ||
// | ||
// This library is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU Lesser General Public | ||
// License as published by the Free Software Foundation; either | ||
// version 2.1 of the License, or (at your option) any later version. | ||
// | ||
// This library is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
// Lesser General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU Lesser General Public | ||
// License along with this library; if not, write to the Free Software | ||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
//////////////////////////////////////////////////////////////////////////////// | ||
|
||
package com.github.checkstyle.regression.report; | ||
|
||
/** | ||
* @author LuoLiangchen | ||
*/ | ||
public class DiffGroovyWrapper { | ||
|
||
} |
50 changes: 50 additions & 0 deletions
50
src/main/java/com/github/checkstyle/regression/report/ScriptDownloader.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
//////////////////////////////////////////////////////////////////////////////// | ||
// checkstyle: Checks Java source code for adherence to a set of rules. | ||
// Copyright (C) 2001-2017 the original author or authors. | ||
// | ||
// This library is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU Lesser General Public | ||
// License as published by the Free Software Foundation; either | ||
// version 2.1 of the License, or (at your option) any later version. | ||
// | ||
// This library is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
// Lesser General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU Lesser General Public | ||
// License along with this library; if not, write to the Free Software | ||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
//////////////////////////////////////////////////////////////////////////////// | ||
|
||
package com.github.checkstyle.regression.report; | ||
|
||
import java.io.File; | ||
import java.io.IOException; | ||
import java.io.InputStream; | ||
import java.net.URL; | ||
|
||
import org.apache.commons.io.FileUtils; | ||
|
||
/** | ||
* Downloads the 'diff.groovy' script from contribution repository. | ||
* @author LuoLiangchen | ||
*/ | ||
public final class ScriptDownloader { | ||
/** Prevents instantiation. */ | ||
private ScriptDownloader() { | ||
} | ||
|
||
/** | ||
* Downloads the 'diff.groovy' script from contribution repository and save it to | ||
* the given destination. The file at {@code dest} will be overwritten if it already exists. | ||
* @param dest the path of the script to save | ||
* @throws IOException failure of downloading or saving | ||
*/ | ||
public static void downloadGroovyScript(String dest) throws IOException { | ||
final String url = "https://raw.githubusercontent.com/checkstyle/" | ||
+ "contribution/master/checkstyle-tester/diff.groovy"; | ||
final InputStream response = new URL(url).openStream(); | ||
FileUtils.copyInputStreamToFile(response, new File(dest)); | ||
} | ||
} |
24 changes: 24 additions & 0 deletions
24
src/main/java/com/github/checkstyle/regression/report/package-info.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
//////////////////////////////////////////////////////////////////////////////// | ||
// checkstyle: Checks Java source code for adherence to a set of rules. | ||
// Copyright (C) 2001-2017 the original author or authors. | ||
// | ||
// This library is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU Lesser General Public | ||
// License as published by the Free Software Foundation; either | ||
// version 2.1 of the License, or (at your option) any later version. | ||
// | ||
// This library is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
// Lesser General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU Lesser General Public | ||
// License along with this library; if not, write to the Free Software | ||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
//////////////////////////////////////////////////////////////////////////////// | ||
|
||
/** | ||
* Contains the regression test runner and the report deployer. | ||
* @author LuoLiangchen | ||
*/ | ||
package com.github.checkstyle.regression.report; |
36 changes: 36 additions & 0 deletions
36
src/test/java/com/github/checkstyle/regression/report/ScriptDownloaderTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
//////////////////////////////////////////////////////////////////////////////// | ||
// checkstyle: Checks Java source code for adherence to a set of rules. | ||
// Copyright (C) 2001-2017 the original author or authors. | ||
// | ||
// This library is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU Lesser General Public | ||
// License as published by the Free Software Foundation; either | ||
// version 2.1 of the License, or (at your option) any later version. | ||
// | ||
// This library is distributed in the hope that it will be useful, | ||
// but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
// Lesser General Public License for more details. | ||
// | ||
// You should have received a copy of the GNU Lesser General Public | ||
// License along with this library; if not, write to the Free Software | ||
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
//////////////////////////////////////////////////////////////////////////////// | ||
|
||
package com.github.checkstyle.regression.report; | ||
|
||
import static com.github.checkstyle.regression.internal.TestUtils.assertUtilsClassHasPrivateConstructor; | ||
|
||
import org.junit.Test; | ||
|
||
public class ScriptDownloaderTest { | ||
@Test | ||
public void testIsProperUtilsClass() throws Exception { | ||
assertUtilsClassHasPrivateConstructor(ScriptDownloader.class); | ||
} | ||
|
||
@Test | ||
public void testDownloadGroovyScriptNoFailure() throws Exception { | ||
ScriptDownloader.downloadGroovyScript("diff-tool/diff.groovy"); | ||
} | ||
} |