summaryrefslogtreecommitdiffstats
path: root/tests/compExpr-old.test
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2004-05-19 20:15:29 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2004-05-19 20:15:29 (GMT)
commite52d9cbf151b4d4106c36834e820db9442ec9a3b (patch)
treeb07002700fcbcc6b4ed86c424196b744184971a1 /tests/compExpr-old.test
parentcc56afda247802cb646330c25f3f03db20b1a43d (diff)
downloadtcl-e52d9cbf151b4d4106c36834e820db9442ec9a3b.zip
tcl-e52d9cbf151b4d4106c36834e820db9442ec9a3b.tar.gz
tcl-e52d9cbf151b4d4106c36834e820db9442ec9a3b.tar.bz2
Massive test cleanup; all tests are run, and constraints are used where necessary.
Diffstat (limited to 'tests/compExpr-old.test')
-rw-r--r--tests/compExpr-old.test41
1 files changed, 18 insertions, 23 deletions
diff --git a/tests/compExpr-old.test b/tests/compExpr-old.test
index 2c9b778..b3e0677 100644
--- a/tests/compExpr-old.test
+++ b/tests/compExpr-old.test
@@ -12,7 +12,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: compExpr-old.test,v 1.8 2003/09/12 23:55:34 dkf Exp $
+# RCS: @(#) $Id: compExpr-old.test,v 1.9 2004/05/19 20:15:31 dkf Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest
@@ -20,11 +20,9 @@ if {[lsearch [namespace children] ::tcltest] == -1} {
}
if {([catch {expr T1()} msg] == 1) && ($msg == {unknown math function "T1"})} {
- set gotT1 0
- puts "This application hasn't been compiled with the \"T1\" and"
- puts "\"T2\" math functions, so I'll skip some of the expr tests."
+ testConstraint testmathfunctions 0
} else {
- set gotT1 1
+ testConstraint testmathfunctions 1
}
# procedures used below
@@ -600,24 +598,21 @@ test compExpr-old-15.6 {CompileMathFuncCall: missing ')'} {
} {syntax error in expression "sin(1": missing close parenthesis at end of function call
while compiling
"expr sin(1"}
-if $gotT1 {
- test compExpr-old-15.7 {CompileMathFuncCall: call registered math function} {
- expr 2*T1()
- } 246
- test compExpr-old-15.8 {CompileMathFuncCall: call registered math function} {
- expr T2()*3
- } 1035
-
- test compExpr-old-15.9 {CompileMathFuncCall: call registered math function} {
- expr T3(21, 37)
- } 37
- test compExpr-old-15.10 {CompileMathFuncCall: call registered math function} {
- expr T3(21.2, 37)
- } 37.0
- test compExpr-old-15.11 {CompileMathFuncCall: call registered math function} {
- expr T3(-21.2, -17.5)
- } -17.5
-}
+test compExpr-old-15.7 {CompileMathFuncCall: call registered math function} testmathfunctions {
+ expr 2*T1()
+} 246
+test compExpr-old-15.8 {CompileMathFuncCall: call registered math function} testmathfunctions {
+ expr T2()*3
+} 1035
+test compExpr-old-15.9 {CompileMathFuncCall: call registered math function} testmathfunctions {
+ expr T3(21, 37)
+} 37
+test compExpr-old-15.10 {CompileMathFuncCall: call registered math function} testmathfunctions {
+ expr T3(21.2, 37)
+} 37.0
+test compExpr-old-15.11 {CompileMathFuncCall: call registered math function} testmathfunctions {
+ expr T3(-21.2, -17.5)
+} -17.5
test compExpr-old-16.1 {GetToken: checks whether integer token starting with "0x" (e.g., "0x$") is invalid} {
catch {unset a}