summaryrefslogtreecommitdiffstats
path: root/tests/expr-old.test
diff options
context:
space:
mode:
authorhobbs <hobbs>1999-12-04 06:16:48 (GMT)
committerhobbs <hobbs>1999-12-04 06:16:48 (GMT)
commit8bd88ae75ebf3df12baf9472747baf999a089c8c (patch)
treede4d563d31e6b705edb459823af308d53d953c2b /tests/expr-old.test
parent0cbb9c47d7cd5a71ca1189ab216bf3ded3800278 (diff)
downloadtcl-8bd88ae75ebf3df12baf9472747baf999a089c8c.zip
tcl-8bd88ae75ebf3df12baf9472747baf999a089c8c.tar.gz
tcl-8bd88ae75ebf3df12baf9472747baf999a089c8c.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.
Diffstat (limited to 'tests/expr-old.test')
-rw-r--r--tests/expr-old.test10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/expr-old.test b/tests/expr-old.test
index e04aa95..ccb1438 100644
--- a/tests/expr-old.test
+++ b/tests/expr-old.test
@@ -13,7 +13,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: expr-old.test,v 1.6 1999/06/26 03:54:13 jenn Exp $
+# RCS: @(#) $Id: expr-old.test,v 1.7 1999/12/04 06:16:48 hobbs Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -790,7 +790,7 @@ test expr-old-32.48 {math functions in expressions} {
} {1 {can't use floating-point value as argument to srand}}
test expr-old-32.49 {math functions in expressions} {
list [catch {expr srand("")} msg] $msg
-} {1 {can't use non-numeric string as argument to srand}}
+} {1 {argument to math function didn't have numeric value}}
test expr-old-32.50 {math functions in expressions} {
set result [expr round(srand(12345) * 1000)]
for {set i 0} {$i < 10} {incr i} {
@@ -800,7 +800,7 @@ test expr-old-32.50 {math functions in expressions} {
} {97 834 948 36 12 51 766 585 914 784 333}
test expr-old-32.51 {math functions in expressions} {
list [catch {expr {srand([lindex "6ty" 0])}} msg] $msg
-} {1 {can't use non-numeric string as argument to srand}}
+} {1 {argument to math function didn't have numeric value}}
test expr-old-33.1 {conversions and fancy args to math functions} {
expr hypot ( 3 , 4 )
@@ -871,11 +871,11 @@ if $gotT1 {
test expr-old-36.1 {ExprLooksLikeInt procedure} {
list [catch {expr 0289} msg] $msg
-} {1 {syntax error in expression "0289"}}
+} {1 {"0289" is an invalid octal number}}
test expr-old-36.2 {ExprLooksLikeInt procedure} {
set x 0289
list [catch {expr {$x+1}} msg] $msg
-} {1 {can't use floating-point value as operand of "+"}}
+} {1 {can't use invalid octal number as operand of "+"}}
test expr-old-36.3 {ExprLooksLikeInt procedure} {
list [catch {expr 0289.1} msg] $msg
} {0 289.1}