summaryrefslogtreecommitdiffstats
path: root/library/tcltest
diff options
context:
space:
mode:
authorsebres <sebres@users.sourceforge.net>2020-01-30 15:32:51 (GMT)
committersebres <sebres@users.sourceforge.net>2020-01-30 15:32:51 (GMT)
commitf05d9af86d492cd0b158969b5190ccc651e91db4 (patch)
treea6cb0bb0248ef5857e04284962dd102c28c0701e /library/tcltest
parent782689d5eb24cd73d2dfaef376d4412246ec6cfa (diff)
downloadtcl-f05d9af86d492cd0b158969b5190ccc651e91db4.zip
tcl-f05d9af86d492cd0b158969b5190ccc651e91db4.tar.gz
tcl-f05d9af86d492cd0b158969b5190ccc651e91db4.tar.bz2
introduces new command and constraint testWithLimit (as include tests/internals.tcl) that can be used to test a code under restricted circumstances (e.g. limited address space)
Diffstat (limited to 'library/tcltest')
-rw-r--r--library/tcltest/tcltest.tcl2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl
index e0c925a..1394949 100644
--- a/library/tcltest/tcltest.tcl
+++ b/library/tcltest/tcltest.tcl
@@ -970,7 +970,7 @@ proc tcltest::testConstraint {constraint {value ""}} {
return $testConstraints($constraint)
}
# Check for boolean values
- if {[catch {expr {$value && $value}} msg]} {
+ if {[catch {expr {$value && 1}} msg]} {
return -code error $msg
}
if {[limitConstraints] && ($constraint ni $Option(-constraints))} {