This is an automated email from the ASF dual-hosted git repository.
markt-asf pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/10.1.x by this push:
new df73d7d95b Fix intermittent TestManagerWebapp.testDeploy failure
df73d7d95b is described below
commit df73d7d95b3a14971c443cd7d2694a58d66ad479
Author: Mark Thomas <[email protected]>
AuthorDate: Wed Dec 2 10:03:31 2026 +0000
Fix intermittent TestManagerWebapp.testDeploy failure
Saving the configuration modifies the deployed context.xml. If the
background
process ran before the test completed it redeployed the web application and
the manager reported it as stopped. Disable auto deployment for the test.
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
---
test/org/apache/catalina/manager/TestManagerWebapp.java | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/test/org/apache/catalina/manager/TestManagerWebapp.java
b/test/org/apache/catalina/manager/TestManagerWebapp.java
index 5ed87d9e15..43a037ed40 100644
--- a/test/org/apache/catalina/manager/TestManagerWebapp.java
+++ b/test/org/apache/catalina/manager/TestManagerWebapp.java
@@ -32,6 +32,7 @@ import org.junit.Test;
import static org.apache.catalina.startup.SimpleHttpClient.CRLF;
import org.apache.catalina.Context;
+import org.apache.catalina.Host;
import org.apache.catalina.Lifecycle;
import org.apache.catalina.LifecycleEvent;
import org.apache.catalina.LifecycleListener;
@@ -280,6 +281,9 @@ public class TestManagerWebapp extends TomcatBaseTest {
// Add host config otherwise there's no JMX deployer bean
HostConfig hostConfig = new HostConfig();
ctx.getParent().addLifecycleListener(hostConfig);
+ // Saving the configuration modifies the deployed context.xml. Do not
let the background process notice that
+ // and redeploy the web application part way through the test.
+ ((Host) ctx.getParent()).setAutoDeploy(false);
tomcat.start();
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]