-
Notifications
You must be signed in to change notification settings - Fork 106
/
.travis.yml
40 lines (33 loc) · 1.22 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
language: php
dist: trusty
php:
- 5.6
- 7.1
- 7.2
- 7.3
env:
- GOOGLE_CLOUD_STORAGE="1.0.*"
- GOOGLE_CLOUD_STORAGE="1.1.*"
- GOOGLE_CLOUD_STORAGE="1.2.*"
- GOOGLE_CLOUD_STORAGE="1.3.*"
- GOOGLE_CLOUD_STORAGE="1.4.*"
- GOOGLE_CLOUD_STORAGE="1.5.*"
- RELEASE_TAG=1 # dev-master
- RELEASE_TAG=2 # latest-stable
- RELEASE_TAG=3 # previous-stable
matrix:
fast_finish: true
allow_failures:
- env: RELEASE_TAG=1
before_install:
- bash -c 'if [[ "${TRAVIS_PHP_VERSION}" == "hhvm" ]]; then rm phpunit.xml; mv phpunit.hhvm.xml phpunit.xml; fi;'
install:
- if [[ -z "$GOOGLE_CLOUD_STORAGE" ]]; then GOOGLE_CLOUD_STORAGE=$(travis_retry composer show google/cloud-storage -a | grep versions | cut -d "," -f ${RELEASE_TAG} | sed -e "s/^versions ://" | xargs); fi;
- travis_retry composer require --no-interaction --no-suggest "google/cloud-storage:${GOOGLE_CLOUD_STORAGE}"
- travis_retry composer install --no-interaction --no-suggest
script:
- export GOOGLE_CLOUD_STORAGE=$GOOGLE_CLOUD_STORAGE
- bin/phpunit
after_script:
- wget https://scrutinizer-ci.com/ocular.phar
- bash -c 'if [[ "${TRAVIS_PHP_VERSION}" != "hhvm" ]; then php ocular.phar code-coverage:upload --format=php-clover coverage.xml; fi;'