juergen 2002/06/19 00:42:51
Modified:
testsuite/testsuite/junit/src/org/apache/slide/testsuite/testtools/tprocessor
TErrorsReport.java
Log:
fixed a possible NPE (may occur if the test suite reports exceptions)
Revision Changes Path
1.6 +8 -4
jakarta-slide/testsuite/testsuite/junit/src/org/apache/slide/testsuite/testtools/tprocessor/TErrorsReport.java
Index: TErrorsReport.java
===================================================================
RCS file:
/home/cvs/jakarta-slide/testsuite/testsuite/junit/src/org/apache/slide/testsuite/testtools/tprocessor/TErrorsReport.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- TErrorsReport.java 25 Apr 2002 21:15:13 -0000 1.5
+++ TErrorsReport.java 19 Jun 2002 07:42:51 -0000 1.6
@@ -155,7 +155,10 @@
continue;
cause = cause+"- "+xse.getName()+": ";
}
- cause = cause+xs.getChild("method").getTextTrim()+"
"+xs.getChild("url").getTextTrim()+"\n";
+ // if an exception occured, no method or url may be present
+ if (xs.getChild("method") != null && xs.getChild("url") !=
null) {
+ cause = cause+xs.getChild("method").getTextTrim()+"
"+xs.getChild("url").getTextTrim()+"\n";
+ }
}
if( error ) {
String l = tc.getChild("fileName").getText();
@@ -171,5 +174,6 @@
catch( Exception x ) { x.printStackTrace(); }
}
}
+
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>