test(aio): fix the `deploy-to-firebase` tests

This commit also ensures that if the tests fail, the script exits with an error.
This commit is contained in:
Georgios Kalpakas 2017-08-09 02:22:12 +03:00 committed by Victor Berchet
parent 6fb5250185
commit b14250bef9
1 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,5 @@
#!/usr/bin/env bash
set +x -eu -o pipefail
function check {
if [[ $1 == $2 ]]; then
@ -133,11 +134,11 @@ We only deploy archive branches with the major version less than the stable bran
export TRAVIS_PULL_REQUEST=false
export TRAVIS_BRANCH=2.4.x
export STABLE_BRANCH=2.2.x
export TRAVIS_COMMIT=$(git ls-remote origin 2.1.x | cut -c-40)
export TRAVIS_COMMIT=$(git ls-remote origin 2.4.x | cut -c-40)
export FIREBASE_TOKEN=XXXXX
`dirname $0`/deploy-to-firebase.sh --dry-run
)
expected="Skipping deploy of branch \"2.1.x\" to firebase.
expected="Skipping deploy of branch \"2.4.x\" to firebase.
We only deploy archive branches with the major version less than the stable branch: \"2.2.x\""
check "$actual" "$expected"
)