Kaydet (Commit) 4330117f authored tarafından Steffen Grund's avatar Steffen Grund

CHG: added printinmg of StackTrace in case of an exception.

üst 91d690c7
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: ComplexTestCase.java,v $ * $RCSfile: ComplexTestCase.java,v $
* *
* $Revision: 1.4 $ * $Revision: 1.5 $
* *
* last change: $Date: 2003-03-26 14:53:53 $ * last change: $Date: 2003-04-01 09:18:04 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -67,6 +67,7 @@ import lib.TestParameters; ...@@ -67,6 +67,7 @@ import lib.TestParameters;
import com.sun.star.lang.XMultiServiceFactory; import com.sun.star.lang.XMultiServiceFactory;
import share.LogWriter; import share.LogWriter;
import share.ComplexTest; import share.ComplexTest;
import java.io.PrintWriter;
public abstract class ComplexTestCase implements ComplexTest { public abstract class ComplexTestCase implements ComplexTest {
...@@ -109,6 +110,7 @@ public abstract class ComplexTestCase implements ComplexTest { ...@@ -109,6 +110,7 @@ public abstract class ComplexTestCase implements ComplexTest {
if (errorMsg == null) if (errorMsg == null)
errorMsg = ""; errorMsg = "";
log.println("Message: " + errorMsg); log.println("Message: " + errorMsg);
t.printStackTrace((PrintWriter)log);
} }
//executeMethodTests //executeMethodTests
...@@ -134,6 +136,7 @@ public abstract class ComplexTestCase implements ComplexTest { ...@@ -134,6 +136,7 @@ public abstract class ComplexTestCase implements ComplexTest {
log.println(t.toString()); log.println(t.toString());
String msg = t.getMessage(); String msg = t.getMessage();
log.println("Message: " + msg); log.println("Message: " + msg);
t.printStackTrace((PrintWriter)log);
subEntry.State=message + (msg == null?"":msg); subEntry.State=message + (msg == null?"":msg);
subEntry.hasErrorMsg = true; subEntry.hasErrorMsg = true;
subEntry.ErrorMsg = message + "\n" + msg; subEntry.ErrorMsg = message + "\n" + msg;
...@@ -144,6 +147,7 @@ public abstract class ComplexTestCase implements ComplexTest { ...@@ -144,6 +147,7 @@ public abstract class ComplexTestCase implements ComplexTest {
log.println("Message: " + e.getMessage()); log.println("Message: " + e.getMessage());
String msg = e.getMessage(); String msg = e.getMessage();
log.println("Message: " + msg); log.println("Message: " + msg);
e.printStackTrace((PrintWriter)log);
subEntry.State="SKIPPED.FAILED"; subEntry.State="SKIPPED.FAILED";
subEntry.hasErrorMsg = true; subEntry.hasErrorMsg = true;
subEntry.ErrorMsg = (msg == null?"":msg); subEntry.ErrorMsg = (msg == null?"":msg);
...@@ -174,6 +178,7 @@ public abstract class ComplexTestCase implements ComplexTest { ...@@ -174,6 +178,7 @@ public abstract class ComplexTestCase implements ComplexTest {
if (errorMsg == null) if (errorMsg == null)
errorMsg = ""; errorMsg = "";
log.println("Message: " + errorMsg); log.println("Message: " + errorMsg);
t.printStackTrace((PrintWriter)log);
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment