Skip to content

Commit 48c77b2

Browse files
committed
chore(ci): auto sync fly after login for UTs
Before running unit tests, we ensure fly version is consistent with running concourse
1 parent 3bc99d2 commit 48c77b2

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

ci/pipeline.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ jobs:
225225
echo "Testing environment config:"
226226
echo "---------------------------"
227227
echo "System: $(uname -a)"
228-
echo "fly $(fly --version)"
228+
echo "Docker image fly $(fly --version)"
229229
ruby --version
230230
bundle --version
231231
bundle exec rspec --version
@@ -251,11 +251,13 @@ jobs:
251251
git config --global user.name "COA CI"
252252
echo "Running tests for $GIT_COMMIT_SHA@$GIT_BRANCH"
253253
fly -t cf-ops-automation login -u ((concourse-username)) -p '((concourse-password))' -k -c ((concourse-url))
254+
echo "Ensure local fly version is in sync with concourse"
255+
fly -t cf-ops-automation sync
254256
echo "Setup Code Climate coverage"
255257
cc-test-reporter before-build
256258
bundle exec rspec --format documentation --format html --out ../test-reports/rspec-results.html
257259
echo "Sending coverage to Code Climate"
258-
if [[ $(cc-test-reporter after-build) -eq 0 ]]; then
260+
if [ $(cc-test-reporter after-build) -eq 0 ]; then
259261
echo "Failed to run cc-test-reporter. Re-launch in debug mode";
260262
echo "---------------------------"
261263
cc-test-reporter after-build -d;

0 commit comments

Comments
 (0)