added make test and make valgrindtest targets
authorAndrew Tridgell <tridge@samba.org>
Sat, 28 Apr 2007 08:57:58 +0000 (10:57 +0200)
committerAndrew Tridgell <tridge@samba.org>
Sat, 28 Apr 2007 08:57:58 +0000 (10:57 +0200)
Makefile.in
lib/replace/tests/os2_delete.c [moved from lib/replace/test/os2_delete.c with 100% similarity]
lib/replace/tests/shared_mmap.c [moved from lib/replace/test/shared_mmap.c with 100% similarity]
lib/replace/tests/testsuite.c [moved from lib/replace/test/testsuite.c with 100% similarity]
tests/run_tests.sh [new file with mode: 0755]

index 7837ff1f9103b5e7dd73393a71c056b1a3de7610..a80908c638c60a9c8bc14944aa54b07650bb431e 100644 (file)
@@ -105,12 +105,18 @@ distclean: clean
        rm -f config.log config.status config.cache config.h
        rm -f Makefile
 
-install:
+install: all
        mkdir -p $(bindir)
        mkdir -p $(includedir)
        cp $(BINS) $(bindir)
        cp $(srcdir)/include/ctdb.h $(includedir)
 
+test:
+       tests/run_tests.sh
+
+valgrindtest:
+       VALGRIND="valgrind -q --trace-children=yes" tests/run_tests.sh
+
 
 realdistclean: distclean
        rm -f configure config.h.in
diff --git a/tests/run_tests.sh b/tests/run_tests.sh
new file mode 100755 (executable)
index 0000000..983afa0
--- /dev/null
@@ -0,0 +1,8 @@
+#!/bin/sh
+
+tests/fetch.sh || exit 1
+tests/bench.sh || exit 1
+tests/test.sh || exit 1
+
+echo "All OK"
+exit 0