You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by yo...@apache.org on 2010/10/15 18:25:30 UTC

svn commit: r1022998 - /lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java

Author: yonik
Date: Fri Oct 15 16:25:30 2010
New Revision: 1022998

URL: http://svn.apache.org/viewvc?rev=1022998&view=rev
Log:
tests: log failure to better correlate where it happened

Modified:
    lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java

Modified: lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java?rev=1022998&r1=1022997&r2=1022998&view=diff
==============================================================================
--- lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java (original)
+++ lucene/dev/trunk/solr/src/test/org/apache/solr/SolrTestCaseJ4.java Fri Oct 15 16:25:30 2010
@@ -328,14 +328,18 @@ public abstract class SolrTestCaseJ4 ext
       String results = h.validateXPath(response, tests);
 
       if (null != results) {
-        fail(m + "query failed XPath: " + results +
-             "\n xml response was: " + response +
-             "\n request was: " + req.getParamString());
+        String msg = "REQUEST FAILED: xpath=" + results
+            + "\n\txml response was: " + response
+            + "\n\trequest was:" + req.getParamString();
+
+        log.error(msg);
+        throw new RuntimeException(msg);
       }
 
     } catch (XPathExpressionException e1) {
       throw new RuntimeException("XPath is invalid", e1);
     } catch (Exception e2) {
+      log.error("REQUEST FAILED: " + req.getParamString());
       throw new RuntimeException("Exception during query", e2);
     }
   }