@@ -15,6 +15,11 @@ testConstraint debugpurify [
15
15
&& [testConstraint debug]
16
16
&& [testConstraint purify]
17
17
}]
18
+ testConstraint bigmem [expr {[
19
+ info exists ::env(TCL_TESTCONSTRAINT_BIGMEM)]
20
+ ? !!$::env(TCL_TESTCONSTRAINT_BIGMEM)
21
+ : 1
22
+ }]
18
23
testConstraint fcopy [llength [info commands fcopy]]
19
24
testConstraint fileevent [llength [info commands fileevent]]
20
25
testConstraint thread [expr {![catch {package require Thread 2.7-}]}]
@@ -70,47 +75,47 @@ namespace eval ::tcltests {
70
75
# testnumargs "lappend" "varName" "?value ...?"
71
76
proc testnumargs {cmd {fixed {}} {optional {}} args} {
72
77
variable count
73
- set minargs [llength $fixed ]
74
- set maxargs [expr {$minargs + [llength $optional ]}]
75
- if {[regexp {\.\.\.\??$} [ lindex $optional end] ]} {
76
- unset maxargs; # No upper limit on num of args
77
- }
78
- set message " wrong # args: should be \" $cmd "
79
- if {[llength $fixed ]} {
80
- append message " $fixed "
81
- }
82
- if {[llength $optional ]} {
83
- append message " $optional "
84
- }
85
- if {[llength $fixed ] == 0 && [llength $optional ] == 0} {
86
- append message " \" "
87
- } else {
88
- append message " \" "
89
- }
90
- set label [join $cmd -]
91
- if {$minargs > 0} {
92
- set arguments [lrepeat [expr {$minargs -1}] x]
93
- test $label -minargs-[incr count($label -minargs)] \
78
+ set minargs [llength $fixed ]
79
+ set maxargs [expr {$minargs + [llength $optional ]}]
80
+ if {[regexp {\.\.\.\??$} [ lindex $optional end] ]} {
81
+ unset maxargs; # No upper limit on num of args
82
+ }
83
+ set message " wrong # args: should be \" $cmd "
84
+ if {[llength $fixed ]} {
85
+ append message " $fixed "
86
+ }
87
+ if {[llength $optional ]} {
88
+ append message " $optional "
89
+ }
90
+ if {[llength $fixed ] == 0 && [llength $optional ] == 0} {
91
+ append message " \" "
92
+ } else {
93
+ append message " \" "
94
+ }
95
+ set label [join $cmd -]
96
+ if {$minargs > 0} {
97
+ set arguments [lrepeat [expr {$minargs -1}] x]
98
+ test $label -minargs-[incr count($label -minargs)] \
94
99
" $label no arguments" \
95
- -body " $cmd " \
96
- -result $message -returnCodes error \
97
- {*}$args
98
- if {$minargs > 1} {
99
- test $label -minargs-[incr count($label -minargs)] \
100
+ -body " $cmd " \
101
+ -result $message -returnCodes error \
102
+ {*}$args
103
+ if {$minargs > 1} {
104
+ test $label -minargs-[incr count($label -minargs)] \
100
105
" $label missing arguments" \
101
- -body " $cmd $arguments " \
102
- -result $message -returnCodes error \
103
- {*}$args
104
- }
105
- }
106
- if {[info exists maxargs]} {
107
- set arguments [lrepeat [expr {$maxargs +1}] x]
108
- test $label -maxargs-[incr count($label -maxargs)] \
106
+ -body " $cmd $arguments " \
107
+ -result $message -returnCodes error \
108
+ {*}$args
109
+ }
110
+ }
111
+ if {[info exists maxargs]} {
112
+ set arguments [lrepeat [expr {$maxargs +1}] x]
113
+ test $label -maxargs-[incr count($label -maxargs)] \
109
114
" $label extra arguments" \
110
- -body " $cmd $arguments " \
111
- -result $message -returnCodes error \
112
- {*}$args
113
- }
115
+ -body " $cmd $arguments " \
116
+ -result $message -returnCodes error \
117
+ {*}$args
118
+ }
114
119
}
115
120
116
121
init
0 commit comments