From: antirez Date: Fri, 15 Jul 2011 15:20:57 +0000 (+0200) Subject: Added a 'runtest' script that is responsible to check if Tcl is available and run... X-Git-Url: https://git.saurik.com/redis.git/commitdiff_plain/f790bd028cceca6f19b0690124e913baf897cb0e Added a 'runtest' script that is responsible to check if Tcl is available and run the test. This is invoked from Makefile as well. --- diff --git a/runtest b/runtest new file mode 100755 index 00000000..2ea4d39b --- /dev/null +++ b/runtest @@ -0,0 +1,9 @@ +#!/bin/bash +TCL=tclsh8.5 +which $TCL +if [ "$?" != "0" ] +then + echo "You need '$TCL' in order to run the Redis test" + exit 1 +fi +$TCL tests/test_helper.tcl $* diff --git a/src/Makefile b/src/Makefile index 5354746b..ee4bfc50 100644 --- a/src/Makefile +++ b/src/Makefile @@ -207,7 +207,7 @@ dep: $(CC) -MM *.c -I ../deps/hiredis -I ../deps/linenoise test: redis-server redis-check-aof - @(cd ..; (which tclsh8.5 >/dev/null && tclsh8.5 tests/test_helper.tcl --tags "${TAGS}") || echo "You need to install Tcl (tclsh8.5) in order to run tests.") + @(cd ..; ./runtest) bench: ./redis-benchmark