Test fix for SOLR-4760

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1480998 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Erick Erickson 2013-05-10 12:52:25 +00:00
parent 3a53c33984
commit fddfe20f9d
1 changed files with 6 additions and 2 deletions

View File

@ -433,9 +433,13 @@ public class IndexSchema {
String expression = stepsToPath(SCHEMA, AT + NAME);
Node nd = (Node) xpath.evaluate(expression, document, XPathConstants.NODE);
StringBuilder sb = new StringBuilder();
// Another case where the initialization from the test harness is different than the "real world"
sb.append("[");
sb.append(loader.getCoreProperties().getProperty(NAME));
sb.append("] ");
if (loader.getCoreProperties() != null) {
sb.append(loader.getCoreProperties().getProperty(NAME));
} else {
sb.append("null");
}
if (nd==null) {
sb.append("schema has no name!");
log.warn(sb.toString());