Skip to content

Commit

Permalink
Fail with nonzero status if status code is not 200
Browse files Browse the repository at this point in the history
  • Loading branch information
hydrosquall committed Oct 16, 2018
1 parent cf65876 commit 721575d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ env:
global:
- DOCKER_COMPOSE_VERSION=1.9.0
- AIRFLOW_SLEEP_DURATION=60 # Number of seconds to wait for airflow to start
- METRICS_ENDPOINT=http://localhost:8080/admin/metrics/
- CURL_FLAGS=--show-error --fail

before_install:
- sudo rm /usr/local/bin/docker-compose
Expand All @@ -20,12 +22,12 @@ script:

# Test Airflow 1.8 with Python 2
- cd tests/airflow1.8-py2 && docker-compose up -d
- pwd && sleep ${AIRFLOW_SLEEP_DURATION}
- curl http://localhost:8080/admin/metrics/
- sleep ${AIRFLOW_SLEEP_DURATION}
- curl ${CURL_FLAGS} ${METRICS_ENDPOINT}
- docker-compose down

# Test Airflow 1.9 with Python 3
- cd ../../tests/airflow1.9-py3 && docker-compose up -d
- pwd && sleep ${AIRFLOW_SLEEP_DURATION}
- curl http://localhost:8080/admin/metrics/
- sleep ${AIRFLOW_SLEEP_DURATION}
- curl ${CURL_FLAGS} ${METRICS_ENDPOINT}
- docker-compose down

0 comments on commit 721575d

Please sign in to comment.