diff options
author | pooryorick <com.digitalsmarties@pooryorick.com> | 2019-12-02 22:07:33 (GMT) |
---|---|---|
committer | pooryorick <com.digitalsmarties@pooryorick.com> | 2019-12-02 22:07:33 (GMT) |
commit | 3c7bb58fb953270618d9ddd63057ba42bda4907a (patch) | |
tree | b298c277d7be1a1cf001fbd1388aa69cb0bd4e03 /library | |
parent | cfb43a5a2ca1e9a41718fe79a62316dda7beecdd (diff) | |
parent | 36f4518f890ff81b22fbf1575775ffaf1c1a149b (diff) | |
download | tcl-3c7bb58fb953270618d9ddd63057ba42bda4907a.zip tcl-3c7bb58fb953270618d9ddd63057ba42bda4907a.tar.gz tcl-3c7bb58fb953270618d9ddd63057ba42bda4907a.tar.bz2 |
merge 8.6
Diffstat (limited to 'library')
-rw-r--r-- | library/tcltest/tcltest.tcl | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/library/tcltest/tcltest.tcl b/library/tcltest/tcltest.tcl index 4171965..28c50ef 100644 --- a/library/tcltest/tcltest.tcl +++ b/library/tcltest/tcltest.tcl @@ -2069,7 +2069,9 @@ proc tcltest::test {name description args} { } # Always run the cleanup script - set code [catch {uplevel 1 $cleanup} cleanupMsg] + set code [catch { + uplevel 1 [list [namespace which CleanupTest] $cleanup] + } cleanupMsg] if {$code == 1} { set errorInfo(cleanup) $::errorInfo set errorCodeRes(cleanup) $::errorCode @@ -2382,6 +2384,14 @@ proc tcltest::SetupTest setup { uplevel 1 $setup } + +# CleanupTest -- +# +# Evaluates the -cleanup script for a test +proc tcltest::CleanupTest cleanup { + uplevel 1 $cleanup +} + ##################################################################### # tcltest::cleanupTestsHook -- |