You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by re...@apache.org on 2023/01/18 09:50:16 UTC
[tomcat] branch 8.5.x updated: Pull test validation in a separate validate step
This is an automated email from the ASF dual-hosted git repository.
remm pushed a commit to branch 8.5.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/8.5.x by this push:
new 7421a600f6 Pull test validation in a separate validate step
7421a600f6 is described below
commit 7421a600f6933a6a117bd01965279399248b7afb
Author: remm <re...@apache.org>
AuthorDate: Wed Jan 18 10:37:18 2023 +0100
Pull test validation in a separate validate step
This will allow making the main validation tighter.
Document some validation options as less useful.
---
build.xml | 24 ++++++++++-----
res/checkstyle/checkstyle.xml | 6 ++--
.../{checkstyle.xml => test-checkstyle.xml} | 34 +++-------------------
3 files changed, 24 insertions(+), 40 deletions(-)
diff --git a/build.xml b/build.xml
index f66c834a00..5c07d2b80b 100644
--- a/build.xml
+++ b/build.xml
@@ -593,6 +593,7 @@
<taskdef resource="${checkstyletask.properties}"
classpath="${checkstyle.jar}" />
+ <!-- Main checks -->
<checkstyle config="res/checkstyle/checkstyle.xml">
<fileset dir="." >
<patternset refid="text.files" />
@@ -603,6 +604,7 @@
<exclude name="nbproject/**"/>
<exclude name="output/**"/>
<exclude name="modules/**"/>
+ <exclude name="test/**"/>
<exclude name="**/*.mdl"/>
<exclude name="**/*.pem"/>
<exclude name="**/*.svg"/>
@@ -616,13 +618,6 @@
<exclude name="java/org/apache/**/parser/ParseException.java" />
<exclude name="java/org/apache/**/parser/SimpleCharStream.java" />
<exclude name="java/org/apache/**/parser/Token*.java" />
- <!-- Exclude simple test files -->
- <exclude name="test/webapp/bug53257/**/*.txt"/>
- <exclude name="test/webapp/bug49nnn/bug49464*"/>
- <exclude name="test/webapp-fragments/WEB-INF/classes/*.txt"/>
- <exclude name="test/webresources/**"/>
- <!-- Exclude test files with unusual encodings -->
- <exclude name="test/webapp/jsp/encoding/**"/>
<!-- Exclude developer specific local files -->
<exclude name="build.properties" />
<exclude name="res/maven/mvn.properties" />
@@ -647,6 +642,21 @@
<include name="**/*.java"/>
</fileset>
</checkstyle>
+ <!-- Tests checks -->
+ <checkstyle config="res/checkstyle/test-checkstyle.xml">
+ <fileset dir="test" >
+ <patternset refid="text.files" />
+ <exclude name=".*/**"/>
+ <exclude name="**/*.pem"/>
+ <!-- Exclude simple test files -->
+ <exclude name="webapp/bug53257/**/*.txt"/>
+ <exclude name="webapp/bug49nnn/bug49464*"/>
+ <exclude name="webapp-fragments/WEB-INF/classes/*.txt"/>
+ <exclude name="webresources/**"/>
+ <!-- Exclude test files with unusual encodings -->
+ <exclude name="webapp/jsp/encoding/**"/>
+ </fileset>
+ </checkstyle>
</target>
<target name="validate-eoln" depends="build-prepare,compile-prepare"
diff --git a/res/checkstyle/checkstyle.xml b/res/checkstyle/checkstyle.xml
index 1b23c8df84..1632fd48da 100644
--- a/res/checkstyle/checkstyle.xml
+++ b/res/checkstyle/checkstyle.xml
@@ -87,11 +87,11 @@
<module name="JavadocMissingLeadingAsterisk"/>
<module name="JavadocMissingWhitespaceAfterAsterisk"/>
<module name="JavadocStyle">
- <!-- ~1600 errors -->
+ <!-- Disabled. Large number of errors with minimal benefit to be gained by fixing at this time. ~1600 errors -->
<property name="checkFirstSentence" value="false"/>
- <!-- ~1500 errors -->
+ <!-- Disabled. Large number of errors with minimal benefit to be gained by fixing at this time. ~1500 errors -->
<property name="checkEmptyJavadoc" value="false"/>
- <!-- Does not handle HTML tags in {@code ...} correctly -->
+ <!-- Does not handle HTML tags in {@code ...} correctly -->
<property name="checkHtml" value="false"/>
</module>
<!-- ~9000 errors
diff --git a/res/checkstyle/checkstyle.xml b/res/checkstyle/test-checkstyle.xml
similarity index 80%
copy from res/checkstyle/checkstyle.xml
copy to res/checkstyle/test-checkstyle.xml
index 1b23c8df84..6b2ef6b562 100644
--- a/res/checkstyle/checkstyle.xml
+++ b/res/checkstyle/test-checkstyle.xml
@@ -25,13 +25,13 @@
<!-- Cache what has passed checkstyle -->
<property name="cacheFile"
- value="${tomcat.output}/res/checkstyle/cachefile-checkstyle.xml"/>
+ value="${tomcat.output}/res/checkstyle/cachefile-test-checkstyle.xml"/>
<!-- Headers -->
<module name="RegexpHeader">
<property name="headerFile" value="${basedir}/res/checkstyle/header-al2.txt"/>
<property name="multiLines" value="1, 2, 3, 4"/>
- <property name="fileExtensions" value="java,xml,jsp,txt,sh,bat,properties"/>
+ <property name="fileExtensions" value="java,xml,jsp,txt,sh,bat,properties,yaml"/>
</module>
<!-- Whitespace -->
@@ -69,7 +69,7 @@
<property name="illegalPkgs" value="sun,junit.framework"/>
</module>
<module name="ImportOrder">
- <property name="groups" value="java,javax,org.hamcrest,org.junit,org,async,jsp2,util"/>
+ <property name="groups" value="java,javax,jakarta,org.hamcrest,org.junit,org,async,jsp2,util"/>
<property name="ordered" value="true"/>
<property name="separated" value="true"/>
<property name="option" value="above"/>
@@ -87,46 +87,20 @@
<module name="JavadocMissingLeadingAsterisk"/>
<module name="JavadocMissingWhitespaceAfterAsterisk"/>
<module name="JavadocStyle">
- <!-- ~1600 errors -->
<property name="checkFirstSentence" value="false"/>
- <!-- ~1500 errors -->
<property name="checkEmptyJavadoc" value="false"/>
- <!-- Does not handle HTML tags in {@code ...} correctly -->
+ <!-- Does not handle HTML tags in {@code ...} correctly -->
<property name="checkHtml" value="false"/>
</module>
- <!-- ~9000 errors
- <module name="MissingJavadocMethod"/>
- -->
- <!-- ~1400 errors
- <module name="MissingJavadocType"/>
- -->
<module name="NonEmptyAtclauseDescription"/>
- <!-- ~1600 errors
- <module name="RequireEmptyLineBeforeBlockTagGroup"/>
- -->
<module name="SingleLineJavadoc"/>
- <!-- Miscellaneous -->
- <!-- ~5500 errors
- <module name="Indentation">
- <property name="lineWrappingIndentation" value="8"/>
- </module>
- -->
-
<!-- Modifiers -->
<module name="ModifierOrder"/>
- <!-- ~1750 errors
- <module name="RedundantModifier"/>
- -->
<!-- Whitespace -->
<module name="GenericWhitespace"/>
<module name="EmptyForInitializerPad"/>
<module name="EmptyForIteratorPad"/>
- <!-- ~ 1200 errors
- <module name="OperatorWrap">
- <property name="option" value="eol"/>
- </module>
- -->
</module>
</module>
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org