diff options
| author | pooryorick <com.digitalsmarties@pooryorick.com> | 2021-04-27 10:48:58 (GMT) |
|---|---|---|
| committer | pooryorick <com.digitalsmarties@pooryorick.com> | 2021-04-27 10:48:58 (GMT) |
| commit | c7fcbf756c0b7f4332a6d930cfec58945029eacd (patch) | |
| tree | 89170c7d7c865a6e691bb6f6475a335dc25ff608 | |
| parent | 81d499ea3132322afb4b7b97c56a949ad04609ac (diff) | |
| download | tcl-c7fcbf756c0b7f4332a6d930cfec58945029eacd.zip tcl-c7fcbf756c0b7f4332a6d930cfec58945029eacd.tar.gz tcl-c7fcbf756c0b7f4332a6d930cfec58945029eacd.tar.bz2 | |
Make tcltests.tcl continue to function even if tclTest.c isn't available.
| -rw-r--r-- | tests/tcltests.tcl | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/tests/tcltests.tcl b/tests/tcltests.tcl index 4dea64f..1ee37d3 100644 --- a/tests/tcltests.tcl +++ b/tests/tcltests.tcl @@ -3,16 +3,18 @@ package require tcltest 2.5 namespace import ::tcltest::* testConstraint exec [llength [info commands exec]] -testConstraint debug [testdebug] -testConstraint purify [testpurify] -testConstraint debugpurify [ - expr { - ![testConstraint memory] - && - [testConstraint debug] - && - [testConstraint purify] -}] +if {[namespace which testdebug] ne {}} { + testConstraint debug [testdebug] + testConstraint purify [testpurify] + testConstraint debugpurify [ + expr { + ![testConstraint memory] + && + [testConstraint debug] + && + [testConstraint purify] + }] +} testConstraint fcopy [llength [info commands fcopy]] testConstraint fileevent [llength [info commands fileevent]] testConstraint thread [ |
