diff options
author | hobbs <hobbs@noemail.net> | 2001-11-16 22:28:08 (GMT) |
---|---|---|
committer | hobbs <hobbs@noemail.net> | 2001-11-16 22:28:08 (GMT) |
commit | b63f5ab49abaad98203947f758175d32060eef13 (patch) | |
tree | f80861ce2144fa5e83e5393db6f7692cf63fe0f1 /tests/interp.test | |
parent | a45c9c633c043ea729e8267d537dfe61c6746643 (diff) | |
download | tcl-b63f5ab49abaad98203947f758175d32060eef13.zip tcl-b63f5ab49abaad98203947f758175d32060eef13.tar.gz tcl-b63f5ab49abaad98203947f758175d32060eef13.tar.bz2 |
* tests/interp.test:
* generic/tclInterp.c (SlaveObjCmd): Corrected argument checking
for '$interp alias|aliases|issafe'. [Patch #479560] (thoyts, hobbs)
FossilOrigin-Name: 12ec29d26bfaa8b7bf3aea754214e0204cbac8b4
Diffstat (limited to 'tests/interp.test')
-rw-r--r-- | tests/interp.test | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/interp.test b/tests/interp.test index 0dab342..5d72a7b 100644 --- a/tests/interp.test +++ b/tests/interp.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: interp.test,v 1.12 2001/03/29 23:24:32 mdejong Exp $ +# RCS: @(#) $Id: interp.test,v 1.13 2001/11/16 22:28:08 hobbs Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -259,6 +259,9 @@ test interp-7.4 {testing basic alias creation} { test interp-7.5 {testing basic alias creation} { a aliases } {foo bar} +test interp-7.6 {testing basic aliases arg checking} { + list [catch {a aliases too many args} msg] $msg +} {1 {wrong # args: should be "a aliases"}} # Part 7: testing basic alias invocation test interp-8.1 {testing basic alias invocation} { @@ -271,6 +274,10 @@ test interp-8.2 {testing basic alias invocation} { a alias bar in_master a1 a2 a3 a eval bar s1 s2 s3 } {seen in master: {a1 a2 a3 s1 s2 s3}} +test interp-8.3 {testing basic alias invocation} { + catch {interp create a} + list [catch {a alias} msg] $msg +} {1 {wrong # args: should be "a alias aliasName ?targetName? ?args..?"}} # Part 8: Testing aliases for non-existent targets test interp-9.1 {testing aliases for non-existent targets} { @@ -441,6 +448,10 @@ test interp-13.3 {testing foo issafe} { interp create {a x3 foo} a eval x3 eval foo issafe } 1 +test interp-7.6 {testing issafe arg checking} { + catch {interp create a} + list [catch {a issafe too many args} msg] $msg +} {1 {wrong # args: should be "a issafe"}} # part 14: testing interp aliases test interp-14.1 {testing interp aliases} { |