diff options
author | Steve Bennett <steveb@workware.net.au> | 2011-07-12 19:24:20 +1000 |
---|---|---|
committer | Steve Bennett <steveb@workware.net.au> | 2011-07-13 11:33:35 +1000 |
commit | a36733634abd60b973979431718d4af889611121 (patch) | |
tree | b902adfd7da8ff4b2e7bcd9f87a840980e29b605 | |
parent | 3ad2031b80c957011160de5f8c1eb4f8346df97b (diff) | |
download | jimtcl-a36733634abd60b973979431718d4af889611121.zip jimtcl-a36733634abd60b973979431718d4af889611121.tar.gz jimtcl-a36733634abd60b973979431718d4af889611121.tar.bz2 |
Setup auto_path directly in tests/testing.tcl
Rather than relying on setting JIMLIB in the Makefile.
Makes it easier to run individual tests manually.
Signed-off-by: Steve Bennett <steveb@workware.net.au>
-rw-r--r-- | tests/Makefile | 1 | ||||
-rw-r--r-- | tests/testing.tcl | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/tests/Makefile b/tests/Makefile index caca931..586352a 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -1,6 +1,5 @@ jimsh ?= ../jimsh export LD_LIBRARY_PATH := ..:$(LD_LIBRARY_PATH) -export JIMLIB := ..:. test: @set -e; for i in *.test; do $(jimsh) $$i; done diff --git a/tests/testing.tcl b/tests/testing.tcl index a04c295..6f7a56e 100644 --- a/tests/testing.tcl +++ b/tests/testing.tcl @@ -7,6 +7,7 @@ set testinfo(numtests) 0 set testinfo(failed) {} set testdir [file dirname [info script]] +set bindir [file dirname [info nameofexecutable]] if {[lsearch $argv "-verbose"] >= 0 || [info exists env(testverbose)]} { incr testinfo(verbose) @@ -64,6 +65,8 @@ if {[catch {info version}]} { return } +lappend auto_path $testdir $bindir [file dirname [pwd]] + # For Jim, this is reasonable compatible tcltest proc makeFile {contents name} { set f [open $name w] |