summaryrefslogtreecommitdiffstats
path: root/tests/basic.test
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2004-09-29 22:37:12 (GMT)
committerdgp <dgp@users.sourceforge.net>2004-09-29 22:37:12 (GMT)
commit4b24b8046191325fd397650146bb2b21fbcf7d84 (patch)
tree44271c518785582f94b8bd9c7c1a91296a8e54d7 /tests/basic.test
parent9d8dfabf5faa8cdb48851e1087458f4431ab7f45 (diff)
downloadtcl-4b24b8046191325fd397650146bb2b21fbcf7d84.zip
tcl-4b24b8046191325fd397650146bb2b21fbcf7d84.tar.gz
tcl-4b24b8046191325fd397650146bb2b21fbcf7d84.tar.bz2
* tests/basic.test (49.*): New tests for TCL_EVAL_GLOBAL.
Diffstat (limited to 'tests/basic.test')
-rw-r--r--tests/basic.test22
1 files changed, 21 insertions, 1 deletions
diff --git a/tests/basic.test b/tests/basic.test
index 8b1e00f..9539b72 100644
--- a/tests/basic.test
+++ b/tests/basic.test
@@ -15,7 +15,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: basic.test,v 1.33 2004/09/27 16:24:27 dgp Exp $
+# RCS: @(#) $Id: basic.test,v 1.34 2004/09/29 22:37:13 dgp Exp $
#
package require tcltest 2
@@ -888,6 +888,26 @@ test basic-48.23.$noComp {expansion: handle return codes} -constraints $constrai
} ;# End of noComp loop
+test basic-49.1 {Tcl_EvalEx: verify TCL_EVAL_GLOBAL operation} {
+ set ::x global
+ namespace eval ns {
+ variable x namespace
+ testevalex {set x changed} global
+ set ::result [list $::x $x]
+ }
+ namespace delete ns
+ set ::result
+} {changed namespace}
+test basic-49.2 {Tcl_EvalEx: verify TCL_EVAL_GLOBAL operation} {
+ set ::x global
+ namespace eval ns {
+ variable x namespace
+ testevalex {set ::context $x} global
+ }
+ namespace delete ns
+ set ::context
+} {global}
+
# Clean up after expand tests
unset noComp l1 l2 constraints
rename l3 {}