summaryrefslogtreecommitdiffstats
path: root/tests/thread.test
diff options
context:
space:
mode:
authorJoe Mistachkin <joe@mistachkin.com>2009-10-18 11:15:10 (GMT)
committerJoe Mistachkin <joe@mistachkin.com>2009-10-18 11:15:10 (GMT)
commit23bca215abe8ec0937288f610eac66769b5f7d9c (patch)
tree0d50a447bb2bc6670b5252897304771aa4fe05cc /tests/thread.test
parent156fe3ccca47d40808328dcecb45b444be2ec627 (diff)
downloadtcl-23bca215abe8ec0937288f610eac66769b5f7d9c.zip
tcl-23bca215abe8ec0937288f610eac66769b5f7d9c.tar.gz
tcl-23bca215abe8ec0937288f610eac66769b5f7d9c.tar.bz2
Fix for [Bug 1565466]
Diffstat (limited to 'tests/thread.test')
-rw-r--r--tests/thread.test11
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/thread.test b/tests/thread.test
index 2686720..037766d 100644
--- a/tests/thread.test
+++ b/tests/thread.test
@@ -10,7 +10,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: thread.test,v 1.10 2000/05/02 22:02:36 kupries Exp $
+# RCS: @(#) $Id: thread.test,v 1.10.18.1 2009/10/18 11:15:10 mistachkin Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -204,8 +204,9 @@ test thread-4.3 {TclThreadSend preserve errorInfo} {testthread} {
set len [llength [testthread names]]
set serverthread [testthread create]
set x [catch {testthread send $serverthread {set undef}} msg]
+ set savedErrorInfo $errorInfo
threadReap
- list $len $x $msg $errorInfo
+ list $len $x $msg $savedErrorInfo
} {1 1 {can't read "undef": no such variable} {can't read "undef": no such variable
while executing
"set undef"
@@ -217,8 +218,9 @@ test thread-4.4 {TclThreadSend preserve code} {testthread} {
set len [llength [testthread names]]
set serverthread [testthread create]
set x [catch {testthread send $serverthread {break}} msg]
+ set savedErrorInfo $errorInfo
threadReap
- list $len $x $msg $errorInfo
+ list $len $x $msg $savedErrorInfo
} {1 3 {} {}}
test thread-4.5 {TclThreadSend preserve errorCode} {testthread} {
@@ -226,8 +228,9 @@ test thread-4.5 {TclThreadSend preserve errorCode} {testthread} {
set ::tcltest::mainThread [testthread names]
set serverthread [testthread create]
set x [catch {testthread send $serverthread {error ERR INFO CODE}} msg]
+ set savedErrorCode $errorCode
threadReap
- list $x $msg $errorCode
+ list $x $msg $savedErrorCode
} {1 ERR CODE}