summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2008-09-26 19:36:47 (GMT)
committerdgp <dgp@users.sourceforge.net>2008-09-26 19:36:47 (GMT)
commited14e02fc83fc5a7dab826db93ce7e2d4e276a96 (patch)
tree3de038aa9224dde36f236ff723ee9f565ca49c9a /tests
parent7a8e8db83501823dbe441944d6107f249accb2e8 (diff)
downloadtcl-ed14e02fc83fc5a7dab826db93ce7e2d4e276a96.zip
tcl-ed14e02fc83fc5a7dab826db93ce7e2d4e276a96.tar.gz
tcl-ed14e02fc83fc5a7dab826db93ce7e2d4e276a96.tar.bz2
TIP #323 IMPLEMENTATION (partial)
* doc/namespace.n: Revise [namespace upvar] to accept zero * generic/tclNamesp.c: variable names. * tests/upvar.test:
Diffstat (limited to 'tests')
-rw-r--r--tests/upvar.test15
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/upvar.test b/tests/upvar.test
index bcad004..d774626 100644
--- a/tests/upvar.test
+++ b/tests/upvar.test
@@ -11,7 +11,7 @@
# 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.16 2007/12/13 15:26:07 dgp Exp $
+# RCS: @(#) $Id: upvar.test,v 1.17 2008/09/26 19:36:51 dgp Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest 2
@@ -544,6 +544,19 @@ test upvar-NS-1.9 {nsupvar links to correct variable} \
-returnCodes error \
-cleanup {namespace delete test_ns_1}
+test upvar-NS-2.1 {TIP 323} -returnCodes error -body {
+ namespace upvar
+} -result {wrong # args: should be "namespace upvar ns ?otherVar myVar ...?"}
+
+test upvar-NS-2.1 {TIP 323} -setup {
+ namespace eval test_ns_1 {}
+} -body {
+ namespace upvar test_ns_1
+} -cleanup {
+ namespace delete test_ns_1
+} -result {}
+
+
# cleanup
::tcltest::cleanupTests