mirror of
https://github.com/Raimondi/delimitMate.git
synced 2026-02-20 08:38:35 +08:00
Migrate testing to tcltest + expect
This commit is contained in:
18
test/all.tcl
Normal file
18
test/all.tcl
Normal file
@@ -0,0 +1,18 @@
|
||||
package require tcltest 2
|
||||
namespace import -force ::tcltest::*
|
||||
configure {*}$argv -testdir [file dir [info script]]
|
||||
|
||||
# Hook to determine if any of the tests failed. Then we can exit with
|
||||
# proper exit code: 0=all passed, 1=one or more failed
|
||||
proc tcltest::cleanupTestsHook {} {
|
||||
variable numTests
|
||||
upvar 2 testFileFailures crashed
|
||||
set ::exitCode [expr {$numTests(Failed) > 0}]
|
||||
if {[info exists crashed]} {
|
||||
set ::exitCode [expr {$::exitCode || [llength $crashed]}]
|
||||
}
|
||||
}
|
||||
|
||||
runAllTests
|
||||
puts "\a"
|
||||
exit $exitCode
|
||||
Reference in New Issue
Block a user