diff options
Diffstat (limited to 'tests/platform-ci/ci-build.sh')
-rwxr-xr-x | tests/platform-ci/ci-build.sh | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tests/platform-ci/ci-build.sh b/tests/platform-ci/ci-build.sh index b02fe89d..256164ac 100755 --- a/tests/platform-ci/ci-build.sh +++ b/tests/platform-ci/ci-build.sh @@ -140,6 +140,29 @@ run() { test } +upgrade_test() { + # Checkout stable branch containing last release + # and deploy this + cd "$PLATFORMDIR" + git remote add leap https://leap.se/git/leap_platform + git fetch leap + git checkout -b leap_stable remotes/leap/stable + cd "$PROVIDERDIR" + build_from_scratch + deploy + test + + # Checkout HEAD of current branch and re-deploy + cd "$PLATFORMDIR" + git checkout "$CI_COMMIT_REF" + cd "$PROVIDERDIR" + deploy + test + + cleanup + +} + cleanup() { # if everything succeeds, destroy the vm LEAP_CMD vm rm "${TAG}" @@ -184,6 +207,9 @@ case "$CI_JOB_NAME" in test cleanup ;; + upgrade_test) + upgrade_test + ;; *) fail "Don't know what to do for \$CI_JOB_NAME \"$CI_JOB_NAME\"!" ;; |