diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2019-01-03 17:00:00 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2019-01-03 17:00:00 (GMT) |
commit | 68fa646bdcb53bfe8ec99f39e951bca5160cd9d6 (patch) | |
tree | c0b5a34c8133eac42398916fd1a74577d88071c1 /tls/tests/all.tcl | |
parent | 647e9b1a5bcfafcb6c4545e2e4fb43cf93ef1ef6 (diff) | |
parent | 15cf84c34642af290d1fdf16011f9290c941fa13 (diff) | |
download | blt-68fa646bdcb53bfe8ec99f39e951bca5160cd9d6.zip blt-68fa646bdcb53bfe8ec99f39e951bca5160cd9d6.tar.gz blt-68fa646bdcb53bfe8ec99f39e951bca5160cd9d6.tar.bz2 |
Merge commit '15cf84c34642af290d1fdf16011f9290c941fa13' as 'tls'
Diffstat (limited to 'tls/tests/all.tcl')
-rw-r--r-- | tls/tests/all.tcl | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/tls/tests/all.tcl b/tls/tests/all.tcl new file mode 100644 index 0000000..aeb37a8 --- /dev/null +++ b/tls/tests/all.tcl @@ -0,0 +1,56 @@ +# all.tcl -- +# +# This file contains a top-level script to run all of the Tcl +# tests. Execute it by invoking "source all.test" when running tcltest +# in this directory. +# +# Copyright (c) 1998-2000 by Ajuba Solutions. +# All rights reserved. +# +# RCS: @(#) $Id: all.tcl,v 1.5 2000/08/15 18:45:01 hobbs Exp $ + +if {[lsearch [namespace children] ::tcltest] == -1} { + package require tcltest + namespace import ::tcltest::* +} + +set ::tcltest::testSingleFile false +set ::tcltest::testsDirectory [file dir [info script]] + +# We should ensure that the testsDirectory is absolute. +# This was introduced in Tcl 8.3+'s tcltest, so we need a catch. +catch {::tcltest::normalizePath ::tcltest::testsDirectory} + +puts stdout "Tests running in interp: [info nameofexecutable]" +puts stdout "Tests running in working dir: $::tcltest::testsDirectory" +if {[llength $::tcltest::skip] > 0} { + puts stdout "Skipping tests that match: $::tcltest::skip" +} +if {[llength $::tcltest::match] > 0} { + puts stdout "Only running tests that match: $::tcltest::match" +} + +if {[llength $::tcltest::skipFiles] > 0} { + puts stdout "Skipping test files that match: $::tcltest::skipFiles" +} +if {[llength $::tcltest::matchFiles] > 0} { + puts stdout "Only sourcing test files that match: $::tcltest::matchFiles" +} + +set timeCmd {clock format [clock seconds]} +puts stdout "Tests began at [eval $timeCmd]" + +# source each of the specified tests +foreach file [lsort [::tcltest::getMatchingFiles]] { + set tail [file tail $file] + puts stdout $tail + if {[catch {source $file} msg]} { + puts stdout $msg + } +} + +# cleanup +puts stdout "\nTests ended at [eval $timeCmd]" +::tcltest::cleanupTests 1 +return + |