mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-14 11:27:00 +00:00
enhance travis setup
- require php 7 pass (except with extension) - use container-based infrastructure - composer self-update to get rid of the outdated warning - install --prefer-source because travis auth fails against dist
This commit is contained in:
+11
-8
@@ -1,5 +1,7 @@
|
||||
language: php
|
||||
|
||||
sudo: false
|
||||
|
||||
php:
|
||||
- 5.2
|
||||
- 5.3
|
||||
@@ -9,25 +11,26 @@ php:
|
||||
- hhvm
|
||||
- nightly
|
||||
|
||||
allow_failures:
|
||||
- php: nightly
|
||||
|
||||
env:
|
||||
- TWIG_EXT=no
|
||||
- TWIG_EXT=yes
|
||||
|
||||
before_script:
|
||||
- if [ "$TWIG_EXT" == "yes" ]; then sh -c "cd ext/twig && phpize && ./configure --enable-twig && make && sudo make install"; fi
|
||||
- if [ "$TWIG_EXT" == "yes" ]; then echo "extension=twig.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`; fi
|
||||
- if [ ${TRAVIS_PHP_VERSION:0:3} == "5.2" ]; then sed -i.bak "s|vendor/autoload.php|test/bootstrap.php|" phpunit.xml.dist; fi
|
||||
before_install:
|
||||
- if [ ${TRAVIS_PHP_VERSION:0:3} != "5.2" ]; then composer self-update; fi
|
||||
|
||||
install:
|
||||
# Composer is not available on PHP 5.2
|
||||
- if [ ${TRAVIS_PHP_VERSION:0:3} != "5.2" ]; then travis_retry composer install; fi
|
||||
- if [ ${TRAVIS_PHP_VERSION:0:3} != "5.2" ]; then travis_retry composer install --prefer-source; fi
|
||||
|
||||
before_script:
|
||||
- if [ "$TWIG_EXT" == "yes" ]; then sh -c "cd ext/twig && phpize && ./configure --enable-twig && make && make install"; fi
|
||||
- if [ "$TWIG_EXT" == "yes" ]; then echo "extension=twig.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`; fi
|
||||
- if [ ${TRAVIS_PHP_VERSION:0:3} == "5.2" ]; then sed -i.bak "s|vendor/autoload.php|test/bootstrap.php|" phpunit.xml.dist; fi
|
||||
|
||||
matrix:
|
||||
exclude:
|
||||
- php: hhvm
|
||||
env: TWIG_EXT=yes
|
||||
allow_failures:
|
||||
- php: nightly
|
||||
env: TWIG_EXT=yes
|
||||
|
||||
Reference in New Issue
Block a user