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:37:48 UTC
[tomcat] branch main 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 main
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/main by this push:
new 842a463c23 Pull test validation in a separate validate step
842a463c23 is described below
commit 842a463c23cad51be147a2c91d98b7c176093956
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} | 30 ++--------------------
3 files changed, 22 insertions(+), 38 deletions(-)
diff --git a/build.xml b/build.xml
index 035be1ade6..9ed54055d5 100644
--- a/build.xml
+++ b/build.xml
@@ -836,6 +836,7 @@
<taskdef resource="${checkstyletask.properties}"
classpath="${checkstyle.jar}" />
+ <!-- Main checks -->
<checkstyle config="res/checkstyle/checkstyle.xml">
<fileset dir="." >
<patternset refid="text.files" />
@@ -846,6 +847,7 @@
<exclude name="nbproject/**"/>
<exclude name="output/**"/>
<exclude name="modules/**"/>
+ <exclude name="test/**"/>
<exclude name="**/*.mdl"/>
<exclude name="**/*.pem"/>
<exclude name="**/*.svg"/>
@@ -860,13 +862,6 @@
<exclude name="java/org/apache/**/parser/SimpleCharStream.java" />
<exclude name="java/org/apache/**/parser/Token*.java" />
<exclude name="java/org/apache/tomcat/util/json/*.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" />
@@ -891,6 +886,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 8eae3cd4ce..80589e1168 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 83%
copy from res/checkstyle/checkstyle.xml
copy to res/checkstyle/test-checkstyle.xml
index 8eae3cd4ce..6b2ef6b562 100644
--- a/res/checkstyle/checkstyle.xml
+++ b/res/checkstyle/test-checkstyle.xml
@@ -25,7 +25,7 @@
<!-- 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">
@@ -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"/>
- <!-- ~ 1100 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