# HG changeset patch # User Claus Gittinger # Date 1024489261 -7200 # Node ID 2ff4508f476d4eda208947da6df9fd61409b6bed # Parent c5bff082e12fd719301fe510f020a12c9e599ab3 *** empty log message *** diff -r c5bff082e12f -r 2ff4508f476d TestCase.st --- a/TestCase.st Thu May 16 14:28:04 2002 +0200 +++ b/TestCase.st Wed Jun 19 14:21:01 2002 +0200 @@ -120,6 +120,13 @@ ^true ! ! +!TestCase methodsFor:'Accessing'! + +unfinished + + "indicates an unfinished test" +! ! + !TestCase methodsFor:'accessing'! assert: aBoolean @@ -298,6 +305,7 @@ run: aResult beforeEachDo:block1 afterEachDo:block2 block1 value:self value:aResult. +"/testSelector == #testReadStatement ifTrue:[self halt]. aResult runCase: self. block2 value:self value:aResult. ! @@ -333,6 +341,6 @@ !TestCase class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/goodies/sunit/TestCase.st,v 1.23 2002-05-16 12:28:04 james Exp $' + ^ '$Header: /cvs/stx/stx/goodies/sunit/TestCase.st,v 1.24 2002-06-19 12:20:53 cg Exp $' ! ! TestCase initialize! diff -r c5bff082e12f -r 2ff4508f476d TestResource.st --- a/TestResource.st Thu May 16 14:28:04 2002 +0200 +++ b/TestResource.st Wed Jun 19 14:21:01 2002 +0200 @@ -33,9 +33,11 @@ ! reset - current notNil ifTrue: - [current tearDown. - current := nil] + current notNil ifTrue: + [current tearDown. + current := nil] + + "self withAllSubclassesDo:[:each| each reset]" ! ! !TestResource class methodsFor:'testing'! @@ -77,6 +79,7 @@ !TestResource methodsFor:'init / release'! initialize + self setUp ! ! !TestResource methodsFor:'printing'! @@ -112,5 +115,5 @@ !TestResource class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/goodies/sunit/TestResource.st,v 1.2 2002-02-26 10:30:15 cg Exp $' + ^ '$Header: /cvs/stx/stx/goodies/sunit/TestResource.st,v 1.3 2002-06-19 12:21:01 cg Exp $' ! ! diff -r c5bff082e12f -r 2ff4508f476d TestResult.st --- a/TestResult.st Thu May 16 14:28:04 2002 +0200 +++ b/TestResult.st Wed Jun 19 14:21:01 2002 +0200 @@ -98,7 +98,8 @@ runCount (self passedCount + self failureCount + self errorCount) ~~ runCount ifTrue:[ - self halt + Transcript showCR:'oops - inconsistent runCount (errors in cleanup-ensures)'. + "/ self halt:'oops - inconsistent runCount (errors in cleanup-ensures)' ]. "/ ^self passedCount + self failureCount + self errorCount @@ -195,5 +196,5 @@ !TestResult class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/goodies/sunit/TestResult.st,v 1.9 2002-02-26 10:30:45 cg Exp $' + ^ '$Header: /cvs/stx/stx/goodies/sunit/TestResult.st,v 1.10 2002-06-19 12:20:57 cg Exp $' ! ! diff -r c5bff082e12f -r 2ff4508f476d TestRunner.st --- a/TestRunner.st Thu May 16 14:28:04 2002 +0200 +++ b/TestRunner.st Wed Jun 19 14:21:01 2002 +0200 @@ -650,7 +650,7 @@ self displayDetails:(caseName , '...'). testsWhichFailed remove:caseName ifAbsent:nil. - testsWhichPassed remove:caseName ifAbsent:nil. + testsWhichPassed add:caseName. ] afterEachDo:[:eachCaseOrSuite :eachResult | |caseName passed errorCountAfter failureCountAfter| @@ -665,8 +665,8 @@ & (failureCountAfter == failureCountBefore). passed == true ifTrue:[ - testsWhichPassed add:caseName. - testsWhichFailed remove:caseName ifAbsent:nil. +"/ testsWhichPassed add:caseName. +"/ testsWhichFailed remove:caseName ifAbsent:nil. ] ifFalse:[ testsWhichFailed add:caseName. testsWhichPassed remove:caseName ifAbsent:nil. @@ -679,6 +679,7 @@ self hidePercentageIndicator. self displayNormalColorInProgress. ]. + self updateWindow ] ! @@ -1067,5 +1068,5 @@ !TestRunner class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/goodies/sunit/TestRunner.st,v 1.32 2002-02-26 10:30:40 cg Exp $' + ^ '$Header: /cvs/stx/stx/goodies/sunit/TestRunner.st,v 1.33 2002-06-19 12:20:41 cg Exp $' ! !