summaryrefslogtreecommitdiffstats
path: root/tests/upvar.test
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2006-04-06 18:19:22 (GMT)
committerdgp <dgp@users.sourceforge.net>2006-04-06 18:19:22 (GMT)
commit5236fc67c64ed64fa5b75bc48a4ef5dd2ae44e0f (patch)
tree8972f9a966520304e7c3505242e7e72873dfdf9d /tests/upvar.test
parentc1ce8705873d255a95b5b41c4ade4f70afef5422 (diff)
downloadtcl-5236fc67c64ed64fa5b75bc48a4ef5dd2ae44e0f.zip
tcl-5236fc67c64ed64fa5b75bc48a4ef5dd2ae44e0f.tar.gz
tcl-5236fc67c64ed64fa5b75bc48a4ef5dd2ae44e0f.tar.bz2
* tests/compExpr-old.test: Updated testmathfunctions constraint
* tests/compExpr.test: to post-TIP-232 world. * tests/expr-old.test: * tests/expr.test: * tests/info.test: * tests/indexObj.test: Corrected other test errors revealed by * tests/upvar.test: testing outside the tcltest application.
Diffstat (limited to 'tests/upvar.test')
-rw-r--r--tests/upvar.test10
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/upvar.test b/tests/upvar.test
index 0db9404..134e0c1 100644
--- a/tests/upvar.test
+++ b/tests/upvar.test
@@ -11,10 +11,10 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: upvar.test,v 1.11 2006/02/01 17:48:13 dgp Exp $
+# RCS: @(#) $Id: upvar.test,v 1.12 2006/04/06 18:19:28 dgp Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
- package require tcltest
+ package require tcltest 2
namespace import -force ::tcltest::*
}
@@ -316,11 +316,13 @@ test upvar-8.7 {errors in upvar command} {
proc p1 {} {trace variable a w foo; upvar b a}
list [catch p1 msg] $msg
} {1 {variable "a" has traces: can't use for upvar}}
-test upvar-8.8 {create nested array with upvar} {
+test upvar-8.8 {create nested array with upvar} -body {
proc p1 {} {upvar x(a) b; set b(2) 44}
catch {unset x}
list [catch p1 msg] $msg
-} {1 {can't set "b(2)": variable isn't array}}
+} -cleanup {
+ unset x
+} -result {1 {can't set "b(2)": variable isn't array}}
test upvar-8.9 {upvar won't create namespace variable that refers to procedure variable} {
catch {namespace delete {expand}[namespace children :: test_ns_*]}
catch {rename MakeLink ""}