Skip to content

Apache Lucene open-source search software

SOLR-5764: More improvements.

Uwe Schindler00339db708fe
diff --git a/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java b/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java
index c3fab2e0e5d..03b795d9c0d 100644
--- a/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java
+++ b/solr/test-framework/src/java/org/apache/solr/SolrTestCaseJ4.java
@@ -1669,8 +1669,9 @@ public abstract class SolrTestCaseJ4 extends LuceneTestCase {
if (url != null) {
try {
return new File(url.toURI());
- } catch (URISyntaxException use) {
- // ignore + fall-through
+ } catch (Exception e) {
+ throw new RuntimeException("Resource was found on classpath, but cannot be resolved to a " +
+ "normal file (maybe it is part of a JAR file): " + name);
}
}
final File file = new File(name);