From 0eda0984f26a17ca88ebc052cec78a58fd519a72 Mon Sep 17 00:00:00 2001 From: Markus Unterwaditzer Date: Sat, 1 Oct 2016 20:09:13 +0200 Subject: [PATCH] Fail if hypothesis-upload fails --- .travis.yml | 3 --- Makefile | 9 ++++++--- scripts/make_travisconf.py | 4 ---- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index c58973a..6c6045b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,4 @@ { - "after_script": [ - "if [ \"$BUILD_PRS\" = \"true\" ] || [ \"$TRAVIS_PULL_REQUEST\" = \"false\" ]; then\n scripts/upload-hypothesis-db.sh;\nfi" - ], "branches": { "only": [ "auto", diff --git a/Makefile b/Makefile index 8e8b116..e708675 100644 --- a/Makefile +++ b/Makefile @@ -31,13 +31,16 @@ install-test: install-servers [ $(CI) != "true" ] || pip install coverage codecov test: - set -e; \ if [ "$(CI)" = "true" ]; then \ coverage run --source=vdirsyncer/ --module pytest; \ - codecov; \ else \ py.test; \ - fi + fi; \ + STATUS=$?; \ + set -e; \ + [ "$(CI)" != "true" ] || codecov; \ + [ "$(CI)" != "true" ] || scripts/upload-hypothesis-db.sh; \ + [ "$$STATUS" = "0" ] install-style: install-docs pip install flake8 flake8-import-order flake8-bugbear diff --git a/scripts/make_travisconf.py b/scripts/make_travisconf.py index 1b0ce18..ea17b39 100644 --- a/scripts/make_travisconf.py +++ b/scripts/make_travisconf.py @@ -35,10 +35,6 @@ cfg['script'] = [script(""" make -e $BUILD; """)] -cfg['after_script'] = [script(""" - scripts/upload-hypothesis-db.sh; -""")] - matrix = [] cfg['matrix'] = {'include': matrix}