diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-12-03 12:59:47 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-12-03 12:59:47 (GMT) |
commit | 5a66f3963733c1ac130f0ee5ad1c9bd1a3ec8a05 (patch) | |
tree | 64943d94a4ea03ecaa2fbff66b43dc136714d235 /library | |
parent | 87baa32396686a50f7edf26c008eba47c5eee671 (diff) | |
parent | c4990c8bf68c57affbfce84c5a261e23db2a7b5e (diff) | |
download | tcl-5a66f3963733c1ac130f0ee5ad1c9bd1a3ec8a05.zip tcl-5a66f3963733c1ac130f0ee5ad1c9bd1a3ec8a05.tar.gz tcl-5a66f3963733c1ac130f0ee5ad1c9bd1a3ec8a05.tar.bz2 |
Merge 8.7
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 -- |