diff options
author | hobbs <hobbs@noemail.net> | 1999-12-04 06:16:48 (GMT) |
---|---|---|
committer | hobbs <hobbs@noemail.net> | 1999-12-04 06:16:48 (GMT) |
commit | 0762eedcad270b926426400ad8da43274e588b59 (patch) | |
tree | de4d563d31e6b705edb459823af308d53d953c2b /tests/string.test | |
parent | 4b9edb852de46f27fc6906222c2514be594e204e (diff) | |
download | tcl-0762eedcad270b926426400ad8da43274e588b59.zip tcl-0762eedcad270b926426400ad8da43274e588b59.tar.gz tcl-0762eedcad270b926426400ad8da43274e588b59.tar.bz2 |
* tests/env.test: removed knownBug limitation from working test
* tests/all.tcl: ensured that ::tcltest::testsDirectory would be
set to an absolute path
* tests/expr-old.test:
* tests/parseExpr.test:
* tests/string.test:
* generic/tclGet.c:
* generic/tclInt.h:
* generic/tclObj.c:
* generic/tclParseExpr.c:
* generic/tclUtil.c:
* generic/tclExecute.c: added TclCheckBadOctal routine to enhance
error message checking for when users use invalid octal numbers
(like 08), as well as replumbed the Expr*Funcs with a new
VerifyExprObjType to simplify type handling.
FossilOrigin-Name: 7b710149dc55805b40af645d646ee7ae9ad44ea9
Diffstat (limited to 'tests/string.test')
-rw-r--r-- | tests/string.test | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/string.test b/tests/string.test index 1e25073..349cba7 100644 --- a/tests/string.test +++ b/tests/string.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: string.test,v 1.21 1999/10/21 02:17:57 hobbs Exp $ +# RCS: @(#) $Id: string.test,v 1.22 1999/12/04 06:16:49 hobbs Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -249,6 +249,13 @@ test string-5.16 {string index, bytearray object with string obj shimmering} { binary scan $str H* dump string compare [string index $str 10] \x00 } 0 +test string-5.17 {string index, bad integer} { + list [catch {string index "abc" 08} msg] $msg +} {1 {bad index "08": must be integer or end?-integer? (looks like invalid octal number)}} +test string-5.18 {string index, bad integer} { + list [catch {string index "abc" end-00289} msg] $msg +} {1 {expected integer but got "-00289" (looks like invalid octal number)}} + proc largest_int {} { # This will give us what the largest valid int on this machine is, |