| 1 | all: run check |
| 2 | |
| 3 | run: |
| 4 | @echo No build needed |
| 5 | ifeq ($(AUTOPKGTEST_TMP),) |
| 6 | @echo NOTE this test uses the system pybuild-autopkgtest, not the working directory |
| 7 | endif |
| 8 | |
| 9 | check: pass fail |
| 10 | |
| 11 | pass: |
| 12 | @echo "==============================================================" |
| 13 | @echo "= pybuild-autopkgtest passes when tests pass =" |
| 14 | @echo "==============================================================" |
| 15 | @echo |
| 16 | pybuild-autopkgtest |
| 17 | test -f marker-before-pybuild-autopkgtest |
| 18 | test -f marker-after-pybuild-autopkgtest |
| 19 | grep '^1$$' marker-PYBUILD_AUTOPKGTEST |
| 20 | @echo '------------------------------' |
| 21 | @echo "OK: pybuild-autopkgtest passed" |
| 22 | @echo '------------------------------' |
| 23 | @echo |
| 24 | |
| 25 | fail: |
| 26 | @echo "==============================================================" |
| 27 | @echo "= pybuild-autopkgtest fails when tests fail =" |
| 28 | @echo "==============================================================" |
| 29 | @echo |
| 30 | ! FAILS=1 pybuild-autopkgtest |
| 31 | @echo '------------------------------' |
| 32 | @echo "OK: pybuild-autopkgtest failed" |
| 33 | @echo '------------------------------' |
| 34 | @echo |
| 35 | |
| 36 | clean: |
| 37 | ifneq ($(AUTOPKGTEST_TMP),) |
| 38 | rm -r $(AUTOPKGTEST_TMP)/* |
| 39 | endif |