From e1df2d62407f2f61b27e60917dabe204ef8240b8 Mon Sep 17 00:00:00 2001 From: Christian Couder Date: Sat, 25 Oct 2014 12:01:00 +0200 Subject: [PATCH] Add test/Makefile to run the test scripts You can use it like this to launch all the test scripts in order: $ cd test $ make rm -r test-results *** t0010-basic-commands.sh *** ok 1 - current dir is writable ok 2 - ipfs version succeeds ok 3 - ipfs version output looks good ok 4 - ipfs help succeeds ok 5 - ipfs help output looks good # passed all 5 test(s) 1..5 ./test-aggregate-results.sh fixed 0 success 5 failed 0 broken 0 total 5 Or you can just run one test like this: $ make t0010-basic-commands.sh *** t0010-basic-commands.sh *** ok 1 - current dir is writable ok 2 - ipfs version succeeds ok 3 - ipfs version output looks good ok 4 - ipfs help succeeds ok 5 - ipfs help output looks good # passed all 5 test(s) 1..5 --- test/Makefile | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 test/Makefile diff --git a/test/Makefile b/test/Makefile new file mode 100644 index 000000000000..f100bb7a3bac --- /dev/null +++ b/test/Makefile @@ -0,0 +1,19 @@ +# Run tests +# +# Copyright (c) 2014 Christian Couder +# + +T = $(sort $(wildcard t[0-9][0-9][0-9][0-9]-*.sh)) + +all: clean $(T) aggregate + +clean: + rm -r test-results + +$(T): + @echo "*** $@ ***"; ./$@ + +aggregate: + ./test-aggregate-results.sh + +.PHONY: all clean $(T) aggregate