handle errors, too.

git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@23708 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
kohsuke committed 2009-11-13 18:40:36 +00:00
1 parent 5406d1c3aa
commit 0241901f48
2 files changed
+4 -4

No files matched your search

@@ -35,14 +35,14 @@ public class FailedTest extends TestCase {
/**
* The failure. If null, the test will succeed, despite the class name.
*/
private final Exception problem;
private final Throwable problem;
public FailedTest(String name, Exception problem) {
public FailedTest(String name, Throwable problem) {
super(name);
this.problem = problem;
}
public FailedTest(Class name, Exception problem) {
public FailedTest(Class name, Throwable problem) {
this(name.getName(),problem);
}
@@ -51,7 +51,7 @@ public class GroupedTest extends TestSuite {
}
// everything went smoothly. report a successful test to make the ends meet
runTest(new FailedTest(getClass(),null),result);
} catch (Exception e) {
} catch (Throwable e) {
// something went wrong
runTest(new FailedTest(getClass(),e),result);
}