You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@solr.apache.org by ds...@apache.org on 2025/12/01 01:24:39 UTC
(solr) 07/12: Tests: SolrJettyTestRule: harden cleanup
This is an automated email from the ASF dual-hosted git repository.
dsmiley pushed a commit to branch branch_10x
in repository https://gitbox.apache.org/repos/asf/solr.git
commit 49d61c96563a960c4534c562efb7a5ee70eaa073
Author: David Smiley <ds...@apache.org>
AuthorDate: Fri Nov 28 01:15:12 2025 -0500
Tests: SolrJettyTestRule: harden cleanup
If we don't insist `jetty` get removed, then one test failure of jetty not stopping can lead to follow-on tests failing as they can't start
---
.../src/java/org/apache/solr/util/SolrJettyTestRule.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/solr/test-framework/src/java/org/apache/solr/util/SolrJettyTestRule.java b/solr/test-framework/src/java/org/apache/solr/util/SolrJettyTestRule.java
index 061bdaa0d5f..467c6bb2b1b 100644
--- a/solr/test-framework/src/java/org/apache/solr/util/SolrJettyTestRule.java
+++ b/solr/test-framework/src/java/org/apache/solr/util/SolrJettyTestRule.java
@@ -55,9 +55,10 @@ public class SolrJettyTestRule extends SolrClientTestRule {
throw e;
} catch (Exception e) {
throw new RuntimeException(e);
+ } finally {
+ jetty = null;
+ enableProxy = false;
}
- jetty = null;
- enableProxy = false;
}
}