Skip to content

Commit

Permalink
Added a 'runtest' script that is responsible to check if Tcl is avail…
Browse files Browse the repository at this point in the history
…able and run the test. This is invoked from Makefile as well.
  • Loading branch information
antirez committed Jul 15, 2011
1 parent 319bb48 commit f790bd0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions runtest
Original file line number Diff line number Diff line change
@@ -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 $*
2 changes: 1 addition & 1 deletion src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit f790bd0

Please sign in to comment.