From 5bce2422e0c9dc73f112ff2300aca82a4e352caa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Vorburger=20=E2=9B=91=EF=B8=8F?= Date: Sat, 14 Dec 2019 15:51:49 +0100 Subject: [PATCH] change .travis.yml to only run docker test if integration test passed --- .travis.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 1d42d3e2da5..0ff199d1de9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -58,9 +58,9 @@ cache: # https://jira.apache.org/jira/browse/FINERACT-732 removed that again, because it made Travis CI fail. script: - date -# using "&&" instead of x2 "-" means that integrationTest does not run if test fails, which makes sense. +# using "&&" instead of several "-" means that integrationTest does not run if test fails, +# and Docker test does not run if integration test fails, which makes PR failure easier to understand. # @see https://docs.travis-ci.com/user/job-lifecycle/#customizing-the-build-phase - - ./gradlew --console=plain licenseMain licenseTest licenseIntegrationTest test && ./gradlew --console=plain integrationTest -# We must stop mysql the mysql system service to avoid port 3306 conflicts (unless we run the mysql in docker-compose on another port; req. FINERACT-773) - - sudo service mysql stop && docker-compose build && docker-compose up -d && sleep 30s && http --verify=no --timeout 240 --check-status get https://localhost:8443/fineract-provider/actuator/health || docker logs fineract_fineract-server_1 + - ./gradlew --console=plain licenseMain licenseTest licenseIntegrationTest test && ./gradlew --console=plain integrationTest && sudo service mysql stop && docker-compose build && docker-compose up -d && sleep 30s && http --verify=no --timeout 240 --check-status get https://localhost:8443/fineract-provider/actuator/health || docker logs fineract_fineract-server_1 +# We stop the mysql system service when running the Docker test to avoid port 3306 conflicts (unless we run the mysql in docker-compose on another port; req. FINERACT-773) # The || docker logs lets use see the root cause in case of failures