diff options
author | dgp <dgp@users.sourceforge.net> | 2002-09-22 18:19:25 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2002-09-22 18:19:25 (GMT) |
commit | e7bb6998a64684a72f4f8ff53809d85c67172cd8 (patch) | |
tree | a417f0dce5b7aa8e5410a3c69bf2ff11f446a798 /library/tcltest | |
parent | 5ae788a0ea469b9c6ae6686982585d236295abcd (diff) | |
download | tcl-e7bb6998a64684a72f4f8ff53809d85c67172cd8.zip tcl-e7bb6998a64684a72f4f8ff53809d85c67172cd8.tar.gz tcl-e7bb6998a64684a72f4f8ff53809d85c67172cd8.tar.bz2 |
* library/tcltest/tcltest.tcl: Corrected [puts -nonewline] within
test bodies. Thanks to Harald Kirsch. [Bug 612786, Patch 612788]
Also corrected reporting of body return code. Thanks to David
Taback [Bug 611922]
* library/tcltest/pkgIndex.tcl: Bump to version 2.2.1.
* tests/tcltest.test: added tests for these bugs.
Diffstat (limited to 'library/tcltest')
-rw-r--r-- | library/tcltest/tcltest.tcl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl index 400e50d..bc912f0 100644 --- a/library/tcltest/tcltest.tcl +++ b/library/tcltest/tcltest.tcl @@ -16,7 +16,7 @@ # Contributions from Don Porter, NIST, 2002. (not subject to US copyright) # All rights reserved. # -# RCS: @(#) $Id: tcltest.tcl,v 1.74 2002/09/22 17:55:38 dgp Exp $ +# RCS: @(#) $Id: tcltest.tcl,v 1.75 2002/09/22 18:19:26 dgp Exp $ package require Tcl 8.3 ;# uses [glob -directory] namespace eval tcltest { @@ -2017,7 +2017,7 @@ proc tcltest::test {name description args} { } } if {$codeFailure} { - switch -- $code { + switch -- $returnCode { 0 { set msg "Test completed normally" } 1 { set msg "Test generated error" } 2 { set msg "Test generated return exception" } @@ -2025,7 +2025,7 @@ proc tcltest::test {name description args} { 4 { set msg "Test generated continue exception" } default { set msg "Test generated exception" } } - puts [outputChannel] "---- $msg; Return code was: $code" + puts [outputChannel] "---- $msg; Return code was: $returnCode" puts [outputChannel] "---- Return code should have been\ one of: $returnCodes" if {[IsVerbose error]} { |