Skip to content

Apache Lucene open-source search software

SOLR-8877: Disable test on environments with whitespace

Uwe Schindlere3b7d8282571
diff --git a/solr/core/src/test/org/apache/solr/util/TestSolrCLIRunExample.java b/solr/core/src/test/org/apache/solr/util/TestSolrCLIRunExample.java
index e8066927084..1a07d3124aa 100644
--- a/solr/core/src/test/org/apache/solr/util/TestSolrCLIRunExample.java
+++ b/solr/core/src/test/org/apache/solr/util/TestSolrCLIRunExample.java
@@ -47,6 +47,7 @@ import org.apache.solr.client.solrj.response.QueryResponse;
import org.apache.solr.cloud.MiniSolrCloudCluster;
import org.apache.solr.common.SolrInputDocument;
import org.junit.After;
+import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test;
import org.slf4j.Logger;
@@ -60,6 +61,12 @@ import org.slf4j.LoggerFactory;
public class TestSolrCLIRunExample extends SolrTestCaseJ4 {
private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
+
+ @BeforeClass
+ public static void beforeClass() throws IOException {
+ assumeFalse("FIXME: This test does not work with whitespace in CWD (https://issues.apache.org/jira/browse/SOLR-8877)",
+ Paths.get(".").toAbsolutePath().toString().contains(" "));
+ }
/**
* Overrides the call to exec bin/solr to start Solr nodes to start them using the Solr test-framework