diff options
Diffstat (limited to '.travis.yml')
-rw-r--r-- | .travis.yml | 25 |
1 files changed, 21 insertions, 4 deletions
diff --git a/.travis.yml b/.travis.yml index 53cf9bb5..c5fe7b01 100644 --- a/.travis.yml +++ b/.travis.yml | |||
@@ -1,5 +1,9 @@ | |||
1 | language: php | 1 | language: php |
2 | 2 | ||
3 | services: | ||
4 | - rabbitmq | ||
5 | - redis | ||
6 | |||
3 | # faster builds on docker-container setup | 7 | # faster builds on docker-container setup |
4 | sudo: false | 8 | sudo: false |
5 | 9 | ||
@@ -15,6 +19,9 @@ cache: | |||
15 | directories: | 19 | directories: |
16 | - vendor | 20 | - vendor |
17 | - $HOME/.composer/cache | 21 | - $HOME/.composer/cache |
22 | - node_modules | ||
23 | - $HOME/.cache/bower | ||
24 | - $HOME/.npm | ||
18 | 25 | ||
19 | php: | 26 | php: |
20 | - 5.5 | 27 | - 5.5 |
@@ -23,6 +30,9 @@ php: | |||
23 | - 7.1 | 30 | - 7.1 |
24 | - nightly | 31 | - nightly |
25 | 32 | ||
33 | node_js: | ||
34 | - "5" | ||
35 | |||
26 | env: | 36 | env: |
27 | - DB=mysql | 37 | - DB=mysql |
28 | - DB=pgsql | 38 | - DB=pgsql |
@@ -52,6 +62,8 @@ matrix: | |||
52 | env: DB=sqlite | 62 | env: DB=sqlite |
53 | - php: 7.0 | 63 | - php: 7.0 |
54 | env: CS_FIXER=run VALIDATE_TRANSLATION_FILE=run DB=sqlite | 64 | env: CS_FIXER=run VALIDATE_TRANSLATION_FILE=run DB=sqlite |
65 | - php: 7.0 | ||
66 | env: DB=sqlite ASSETS=build | ||
55 | allow_failures: | 67 | allow_failures: |
56 | - php: hhvm-3.12 | 68 | - php: hhvm-3.12 |
57 | - php: 7.1 | 69 | - php: 7.1 |
@@ -67,15 +79,20 @@ before_script: | |||
67 | - if [[ ! $PHP = hhvm* ]]; then echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi; | 79 | - if [[ ! $PHP = hhvm* ]]; then echo "memory_limit=-1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/travis.ini; fi; |
68 | # xdebug isn't enable for PHP 7.1 | 80 | # xdebug isn't enable for PHP 7.1 |
69 | - if [[ ! $PHP = hhvm* ]]; then phpenv config-rm xdebug.ini || echo "xdebug not available"; fi | 81 | - if [[ ! $PHP = hhvm* ]]; then phpenv config-rm xdebug.ini || echo "xdebug not available"; fi |
82 | - if [[ $PHP = 5.5 ]]; then composer require "phpunit/phpunit:4.*" --no-update; fi; | ||
70 | - composer self-update --no-progress | 83 | - composer self-update --no-progress |
71 | - if [[ "$DB" = "pgsql" ]]; then psql -c 'create database wallabag_test;' -U postgres; fi; | 84 | - if [[ $DB = pgsql ]]; then psql -c 'create database wallabag_test;' -U postgres; fi; |
85 | |||
86 | install: | ||
87 | - if [[ $ASSETS = build ]]; then source ~/.nvm/nvm.sh && nvm install 5.0; fi; | ||
88 | - if [[ $ASSETS = build ]]; then npm install -g npm@latest; fi; | ||
72 | 89 | ||
73 | before_install: | 90 | before_install: |
74 | - if [[ $TRAVIS_REPO_SLUG = wallabag/wallabag ]]; then cp .composer-auth.json ~/.composer/auth.json; fi; | 91 | - if [[ $TRAVIS_REPO_SLUG = wallabag/wallabag ]]; then cp .composer-auth.json ~/.composer/auth.json; fi; |
75 | 92 | ||
76 | script: | 93 | script: |
77 | - travis_wait composer install --no-interaction --no-progress --prefer-dist -o | 94 | - travis_wait bash install.sh |
78 | - ant prepare-$DB | 95 | - ant prepare-$DB |
79 | - phpunit -v | 96 | - phpunit -v |
80 | - if [ "$CS_FIXER" = "run" ]; then php bin/php-cs-fixer fix src/ --verbose --dry-run ; fi; | 97 | - if [[ $CS_FIXER = run ]]; then php bin/php-cs-fixer fix src/ --verbose --dry-run ; fi; |
81 | - if [ "$VALIDATE_TRANSLATION_FILE" = "run" ]; then php bin/console lint:yaml src/Wallabag/CoreBundle/Resources/translations -v ; fi; | 98 | - if [[ $VALIDATE_TRANSLATION_FILE = run ]]; then php bin/console lint:yaml src/Wallabag/CoreBundle/Resources/translations -v ; fi; |