You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ds...@apache.org on 2026/02/27 10:28:45 UTC
(tomcat) 11/16: Add integration test profile and exclude them from default test run
This is an automated email from the ASF dual-hosted git repository.
dsoumis pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit 4da3309432bea720bebe47b143f77bf2adbaaa99
Author: Dimitris Soumis <ji...@gmail.com>
AuthorDate: Thu Feb 19 17:29:40 2026 +0200
Add integration test profile and exclude them from default test run
---
build.xml | 10 ++++++++++
test-profiles.properties.default | 4 ++++
test/org/apache/tomcat/integration/httpd/TesterHttpd.java | 2 +-
3 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/build.xml b/build.xml
index ab51b97b0a..4a01746ebe 100644
--- a/build.xml
+++ b/build.xml
@@ -2012,6 +2012,9 @@
<condition property="test.name" value="${test.profile.buildutil}">
<equals arg1="@{profile}" arg2="buildutil"/>
</condition>
+ <condition property="test.name" value="${test.profile.integration}">
+ <equals arg1="@{profile}" arg2="integration"/>
+ </condition>
</sequential>
</macrodef>
@@ -2041,6 +2044,11 @@
<equals arg1="${test.profile}" arg2="tribes"/>
</condition>
+ <!-- Special handling for integration profile: include integration tests -->
+ <condition property="test.includeIntegration" value="true">
+ <equals arg1="${test.profile}" arg2="integration"/>
+ </condition>
+
<echo message="Test profile: ${test.profile}"/>
</target>
@@ -2238,6 +2246,8 @@
<exclude name="**/*Performance.java" if="${test.excludePerformance}" />
<!-- Exclude tests that Gump can't compile (unless explicitly requested via buildutil profile) -->
<exclude name="org/apache/tomcat/buildutil/**" unless="test.includeBuildutil" />
+ <!-- Exclude integration tests requiring external binaries (unless explicitly requested via integration profile) -->
+ <exclude name="**/integration/**" unless="test.includeIntegration" />
<!-- Exclude tests that require large heaps -->
<exclude name="**/*LargeHeap.java" unless="${test.includeLargeHeap}" />
</fileset>
diff --git a/test-profiles.properties.default b/test-profiles.properties.default
index da10ee9f2e..4920030801 100644
--- a/test-profiles.properties.default
+++ b/test-profiles.properties.default
@@ -98,3 +98,7 @@ test.profile.tribes=**/tribes/**/*Test*.java
# Build utility test profile: Tests for build tools (normally excluded)
# Note: These tests depend on classes not in output JARs and are excluded by default
test.profile.buildutil=**/buildutil/**/*Test*.java
+
+# Integration test profile: Tests requiring external processes (e.g. httpd)
+# Note: These tests are excluded by default as they require external binaries
+test.profile.integration=**/integration/**/Test*.java
\ No newline at end of file
diff --git a/test/org/apache/tomcat/integration/httpd/TesterHttpd.java b/test/org/apache/tomcat/integration/httpd/TesterHttpd.java
index 7502af76ad..691dd428cd 100644
--- a/test/org/apache/tomcat/integration/httpd/TesterHttpd.java
+++ b/test/org/apache/tomcat/integration/httpd/TesterHttpd.java
@@ -53,7 +53,7 @@ public class TesterHttpd {
}
String httpdPath = System.getProperty(HTTPD_PATH);
- if (httpdPath == null) {
+ if (httpdPath == null || httpdPath.isEmpty()) {
httpdPath = "httpd";
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org