Apache Solr open-source search software
SOLR-8279: One of two tests was not calling TestInjection#clear after using it. Call clear in the Solr base test class instead.
Mark Robert Miller84005ad61f4c
diff --git a/solr/core/src/test/org/apache/solr/cloud/RestartWhileUpdatingTest.java b/solr/core/src/test/org/apache/solr/cloud/RestartWhileUpdatingTest.javaindex f681c527d06..cde4ee7aaa8 100644--- a/solr/core/src/test/org/apache/solr/cloud/RestartWhileUpdatingTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/RestartWhileUpdatingTest.java@@ -74,7 +74,6 @@ public class RestartWhileUpdatingTest extends AbstractFullDistribZkTestBase {System.clearProperty("leaderVoteWait");System.clearProperty("solr.autoCommit.maxTime");System.clearProperty("solr.autoSoftCommit.maxTime");- TestInjection.reset();}@Testdiff --git a/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java b/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.javaindex 94e8d5f84c6..d94e88654d7 100644--- a/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java+++ b/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java@@ -92,6 +92,7 @@ import org.apache.solr.util.RefCounted;import org.apache.solr.util.RevertDefaultThreadHandlerRule;import org.apache.solr.util.SSLTestConfig;import org.apache.solr.util.TestHarness;+import org.apache.solr.util.TestInjection;import org.apache.zookeeper.KeeperException;import org.junit.AfterClass;import org.junit.BeforeClass;@@ -240,6 +241,7 @@ public abstract class SolrTestCaseJ4 extends LuceneTestCase {coreName = DEFAULT_TEST_CORENAME;} finally {ObjectReleaseTracker.clear();+ TestInjection.reset();initCoreDataDir = null;System.clearProperty("zookeeper.forceSync");System.clearProperty("jetty.testMode");