equal
deleted
inserted
replaced
674 |
674 |
675 passed == true ifTrue:[ |
675 passed == true ifTrue:[ |
676 "/ testsWhichPassed add:caseName. |
676 "/ testsWhichPassed add:caseName. |
677 "/ testsWhichFailed remove:caseName ifAbsent:nil. |
677 "/ testsWhichFailed remove:caseName ifAbsent:nil. |
678 ] ifFalse:[ |
678 ] ifFalse:[ |
679 self testFailed:caseName |
679 self testFailed:caseName withResult:result |
680 ]. |
680 ]. |
681 errorCountBefore := errorCountAfter. |
681 errorCountBefore := errorCountAfter. |
682 failureCountBefore := failureCountAfter |
682 failureCountBefore := failureCountAfter |
683 ] |
683 ] |
684 ] ensure: [ |
684 ] ensure: [ |
834 |
834 |
835 testsWhichPassed := Set new. |
835 testsWhichPassed := Set new. |
836 testsWhichFailed := Set new. |
836 testsWhichFailed := Set new. |
837 |
837 |
838 TestCase allSubclassesDo:[:cls | |
838 TestCase allSubclassesDo:[:cls | |
839 cls lastTestrunResultOrNil == true ifTrue:[ |
839 |lastResult className| |
840 testsWhichPassed add:(cls name) |
840 |
841 ] ifFalse:[ |
841 lastResult := cls lastTestRunResultOrNil. |
842 cls lastTestrunResultOrNil == false ifTrue:[ |
842 lastResult notNil ifTrue:[ |
843 testsWhichFailed add:(cls name) |
843 className := cls name. |
|
844 lastResult == true ifTrue:[ |
|
845 testsWhichPassed add:className |
|
846 ] ifFalse:[ |
|
847 testsWhichFailed add:className |
844 ] |
848 ] |
845 ] |
849 ] |
846 ]. |
850 ]. |
847 ! |
851 ! |
848 |
852 |
900 ^ '' |
904 ^ '' |
901 ]. |
905 ]. |
902 ^ self scriptModel value at:scriptIndex ifAbsent:nil. |
906 ^ self scriptModel value at:scriptIndex ifAbsent:nil. |
903 ! |
907 ! |
904 |
908 |
905 testFailed:caseName |
909 testFailed:caseName withResult:result |
906 |cls| |
910 |cls| |
907 |
911 . |
908 self removeFromPassedTests:caseName. |
912 self removeFromPassedTests:caseName. |
909 self addToFailedTests:caseName. |
913 self addToFailedTests:caseName. |
910 |
914 |
911 (cls := Smalltalk classNamed:caseName) notNil ifTrue:[ |
915 (cls := Smalltalk classNamed:caseName) notNil ifTrue:[ |
912 cls rememberFailedTestRun |
916 cls rememberFailedTestRunWithResult:result. |
913 ]. |
917 ]. |
914 ! |
918 ! |
915 |
919 |
916 testPassed:caseName |
920 testPassed:caseName |
917 |cls| |
921 |cls| |
1105 |
1109 |
1106 script notNil ifTrue:[ |
1110 script notNil ifTrue:[ |
1107 result hasPassed ifTrue:[ |
1111 result hasPassed ifTrue:[ |
1108 self testPassed:script |
1112 self testPassed:script |
1109 ] ifFalse:[ |
1113 ] ifFalse:[ |
1110 self testFailed:script |
1114 self testFailed:script withResult:result |
1111 ]. |
1115 ]. |
1112 ]. |
1116 ]. |
1113 ! |
1117 ! |
1114 |
1118 |
1115 updateWindow |
1119 updateWindow |
1121 ! ! |
1125 ! ! |
1122 |
1126 |
1123 !TestRunner class methodsFor:'documentation'! |
1127 !TestRunner class methodsFor:'documentation'! |
1124 |
1128 |
1125 version |
1129 version |
1126 ^ '$Header: /cvs/stx/stx/goodies/sunit/TestRunner.st,v 1.44 2002-11-07 18:03:46 cg Exp $' |
1130 ^ '$Header: /cvs/stx/stx/goodies/sunit/TestRunner.st,v 1.45 2002-11-11 09:50:19 cg Exp $' |
1127 ! ! |
1131 ! ! |