diff options
author | Jakub Jirutka <jakub@jirutka.cz> | 2017-06-10 14:57:47 +0200 |
---|---|---|
committer | Jakub Jirutka <jakub@jirutka.cz> | 2017-06-11 12:14:41 +0200 |
commit | 69c343afb914f1fdf17c082772bd83be28e0a56b (patch) | |
tree | cc16375be378dd242f225804c7c993086438b139 /test | |
parent | d6ef8fbe23f0b69a7477deeef7284b3f0297d5bb (diff) | |
download | apk-tools-69c343afb914f1fdf17c082772bd83be28e0a56b.tar.gz apk-tools-69c343afb914f1fdf17c082772bd83be28e0a56b.tar.bz2 apk-tools-69c343afb914f1fdf17c082772bd83be28e0a56b.tar.xz apk-tools-69c343afb914f1fdf17c082772bd83be28e0a56b.zip |
test: exit with non-zero status when some root-test fail
Diffstat (limited to 'test')
-rw-r--r-- | test/Makefile | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/Makefile b/test/Makefile index 9a61acb..eefa382 100644 --- a/test/Makefile +++ b/test/Makefile @@ -52,10 +52,11 @@ repos.stamp: $(repos) root-tests: repos.stamp @echo "== Testing `$(APK) --version` (tests that require root permission) ==" - @for i in test*.sh; do \ + @failed=0; for i in test*.sh; do \ rm -f $${i%.sh}.ok ;\ - $(SUDO) $(MAKE) --no-print-directory $${i%.sh}.ok SYSREPO=$(SYSREPO); \ - done + $(SUDO) $(MAKE) --no-print-directory $${i%.sh}.ok SYSREPO=$(SYSREPO) || failed=1; \ + done; \ + return $$failed tests: @echo "== Testing `$(APK) --version` ==" |