diff options
Diffstat (limited to 'tests/switch.test')
-rw-r--r-- | tests/switch.test | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/switch.test b/tests/switch.test index 9a46191..5164ca4 100644 --- a/tests/switch.test +++ b/tests/switch.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: switch.test,v 1.21 2008/03/21 19:09:13 dkf Exp $ +# RCS: @(#) $Id: switch.test,v 1.22 2008/07/21 21:25:22 nijtmans Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest 2 @@ -171,7 +171,7 @@ test switch-4.1 {error in executed command} { "switch a a {error "Just a test"} default {subst 1}"}} test switch-4.2 {error: not enough args} -returnCodes error -body { switch -} -result {wrong # args: should be "switch ?switches? string pattern body ... ?default body?"} +} -result {wrong # args: should be "switch ?-switch ...? string pattern body ?pattern body ...? ?default body?"} test switch-4.3 {error: pattern with no body} -body { switch a b } -returnCodes error -result {extra switch pattern with no body} @@ -271,16 +271,16 @@ test switch-8.3 {weird body text, variable} { test switch-9.1 {empty pattern/body list} -returnCodes error -body { switch x -} -result {wrong # args: should be "switch ?switches? string pattern body ... ?default body?"} +} -result {wrong # args: should be "switch ?-switch ...? string pattern body ?pattern body ...? ?default body?"} test switch-9.2 {unpaired pattern} -returnCodes error -body { switch -- x } -result {extra switch pattern with no body} test switch-9.3 {empty pattern/body list} -body { switch x {} -} -returnCodes error -result {wrong # args: should be "switch ?switches? string {pattern body ... ?default body?}"} +} -returnCodes error -result {wrong # args: should be "switch ?-switch ...? string {pattern body ?pattern body ...? ?default body?}"} test switch-9.4 {empty pattern/body list} -body { switch -- x {} -} -returnCodes error -result {wrong # args: should be "switch ?switches? string {pattern body ... ?default body?}"} +} -returnCodes error -result {wrong # args: should be "switch ?-switch ...? string {pattern body ?pattern body ...? ?default body?}"} test switch-9.5 {unpaired pattern} -body { switch x a {} b } -returnCodes error -result {extra switch pattern with no body} |