diff options
Diffstat (limited to 'tests/opt.test')
-rw-r--r-- | tests/opt.test | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/opt.test b/tests/opt.test index f7491f1..a7e0a11 100644 --- a/tests/opt.test +++ b/tests/opt.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: opt.test,v 1.6 2000/04/10 17:19:02 ericm Exp $ +# RCS: @(#) $Id: opt.test,v 1.7 2000/05/10 23:49:48 hobbs Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -33,9 +33,11 @@ test opt-1.1 {OptKeyRegister / check that auto allocation is skipping existing k } "$n [expr $n+1] [expr $n+2]" test opt-2.1 {OptKeyDelete} { - list [::tcl::OptKeyRegister {} testkey] [::tcl::OptKeyDelete testkey] \ - [catch {::tcl::OptKeyDelete testkey} msg] $msg; -} {testkey {} 1 {can't unset "OptDesc(testkey)": no such element in array}} + list [::tcl::OptKeyRegister {} testkey] \ + [info exists ::tcl::OptDesc(testkey)] \ + [::tcl::OptKeyDelete testkey] \ + [info exists ::tcl::OptDesc(testkey)] +} {testkey 1 {} 0} test opt-3.1 {OptParse / temp key is removed} { |