From a2f9b42f27cda7b00084d8c7cfbcb7d7bcbc0c9f Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Mon, 1 Sep 2008 01:06:09 -0400 Subject: Several improvements to how tests are run. First, if the user hasn't downloaded the monster test database, we just run a simple test of 400 historical games. Second, you can specify the variables START and COUNT on the command line, for running just a part of the huge database. --- Makefile.am | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Makefile.am') diff --git a/Makefile.am b/Makefile.am index 5d0ce08..711161b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -67,12 +67,12 @@ chess-eco.fen: chess-eco.pos chess-eco.el chess-eco.pos chess-eco.fen TESTS = chess-test -DATABASE = test/largedb -START = -FINISH = +DATABASE = $(shell test -r test/largedb.sg3 && echo test/largedb || echo test/historic.pgn) +START = $(shell test -r test/largedb.sg3 && perl -e 'print int(rand(4000000)), "\n";' || echo 1) +COUNT = 100000 -chess-test: Makefile - echo "$(EMACS) -batch -L $(srcdir) -l chess-test.el -f chess-test '$(DATABASE)' $(START) $(FINISH)" > $@ +chess-test: + echo "$(EMACS) -batch -L $(srcdir) -l chess-test.el -f chess-test '$(DATABASE)' $(START) $(COUNT); rm -f $(top_builddir)/chess-test" > $@ chmod u+x $@ TAGS: $(dist_lisp_LISP) -- cgit v1.2.3