From c120bed262ab652b9bb8c793c75becd8fe0357b1 Mon Sep 17 00:00:00 2001 From: Ben Teitelbaum Date: Mon, 20 May 2019 10:11:45 -0700 Subject: [PATCH] add tests_build on branches --- .gitlab-ci.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9da02a2..28bc75f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,6 +16,23 @@ before_script: - gcloud auth list - gcloud --version +# Run tests +test_build: + stage: build + image: blockstream/satapi-builder@sha256:a3a137b80a08325bdd50a7c59ae0429b933e7a36db0d74f6ae34af067dfdee2d + only: + - branches@satellite/ionosphere + except: + - master@satellite/ionosphere + before_script: + - export CHARGE_ROOT=$CHARGE_ROOT_CI + - export REDIS_URI=$REDIS_URI_CI + script: + - bundle exec rake db:create && bundle exec rake db:schema:load && bundle exec rake db:migrate + - bundle exec ruby tests/tests.rb || { echo "Tests failed.."; exit 1; } + - echo "Tests passed!" + - sleep 5000 + # Run tests and build docker images build: stage: build