Skip to content

armgit / solr

Public Imported from GitHub
0

Apache Solr open-source search software

SOLR-6625: Remove RequestInterceptor at the end of the test in BasicHttpSolrClientTest. It was interfering with other tests running the same JVM.

Anshum Gupta57a15d9278ec
diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/BasicHttpSolrClientTest.java b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/BasicHttpSolrClientTest.java
index 5836c6963ce..396b97b0c0d 100644
--- a/solr/solrj/src/test/org/apache/solr/client/solrj/impl/BasicHttpSolrClientTest.java
+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/impl/BasicHttpSolrClientTest.java
@@ -723,6 +723,9 @@ public class BasicHttpSolrClientTest extends SolrJettyTestBase {
} catch (IOException ex) {
throw new RuntimeException(ex);
+ } finally {
+ HttpClientUtil.removeRequestInterceptor(changeRequestInterceptor);
+ HttpClientUtil.removeRequestInterceptor(cookieSettingRequestInterceptor);
}
}