--- a/JUnitTestCaseProxy.st Thu Nov 29 22:49:31 2012 +0000
+++ b/JUnitTestCaseProxy.st Thu Nov 29 22:54:43 2012 +0000
@@ -149,22 +149,22 @@
<resource: #skipInDebuggersWalkBack>
+ | assertions |
+
+ assertions := SignalSet
+ with: JAVA java lang AssertionError
+ with: JAVA junit framework AssertionFailedError.
+
[
self javaClass new perform: testSelector sunitAsSymbol
- ] on: JavaError do: [:ex|
+ ] on: assertions do: [:ex|
"This is the tricky part. We have to auto-magically convert
jUnit's AssertionFailedError to sUnits TestFailure's"
-
- "Bad, bad, I know..."
- (ex parameter class name == #'junit/framework/AssertionFailedError')
- ifTrue:
- [ TestResult failure sunitSignalWith: ex description ]
- ifFalse:
- [ ex pass ]
+ TestResult failure sunitSignalWith: ex getMessage
]
"Created: / 01-03-2011 / 14:50:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
- "Modified: / 05-05-2012 / 22:12:05 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+ "Modified: / 29-11-2012 / 22:18:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !
!JUnitTestCaseProxy class methodsFor:'documentation'!