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
Christian Couder committed
Oct 25, 2014 at 12:01 UTC
aeb019f2b8232c92b13d164ef2011cbdbf9874d0
1 file changed
+20
test/Makefile
new
+20
@@ -0,0 +1,20 @@
1
+# Run tests
2
+#
3
+# Copyright (c) 2014 Christian Couder
4
+# MIT Licensed; see the LICENSE file in this repository.
5
+#
6
+
7
+T = $(sort $(wildcard t[0-9][0-9][0-9][0-9]-*.sh))
8
+
9
+all: clean $(T) aggregate
10
+
11
+clean:
12
+ -rm -r test-results
13
+
14
+$(T):
15
+ @echo "*** $@ ***"; ./$@
16
+
17
+aggregate:
18
+ ./test-aggregate-results.sh
19
+
20
+.PHONY: all clean $(T) aggregate