mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-23 09:53:15 +00:00
67 lines
3.3 KiB
YAML
67 lines
3.3 KiB
YAML
language: php
|
|
|
|
env:
|
|
- SETUP_MODE=update
|
|
- SETUP_MODE=install
|
|
|
|
services:
|
|
- mysql
|
|
- memcached
|
|
- redis
|
|
- elasticsearch
|
|
|
|
before_script:
|
|
- export JS_COMPILER=$TRAVIS_BUILD_DIR/closure/compiler.jar
|
|
- sudo apt-get update -qq && sudo apt-get install -qq scons inkscape python-setuptools
|
|
- sudo easy_install -U taschenmesser scour boto
|
|
- wget http://dl.google.com/closure-compiler/compiler-latest.zip && unzip compiler-latest.zip -d closure
|
|
- node --version
|
|
- npm --version
|
|
- travis_retry npm install
|
|
- echo '' > ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/xdebug.ini
|
|
- sh -c 'if [ $(php -r "echo PHP_MINOR_VERSION;") -le 4 ]; then echo "extension = apc.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini; fi;'
|
|
- echo 'extension="redis.so"' > ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/redis.ini
|
|
- echo 'extension="memcache.so"' > ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/memcache.ini
|
|
- echo 'extension="memcached.so"' > ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/memcached.ini
|
|
- echo "extension=zmq.so" > ~/.phpenv/versions/$(phpenv version-name)/etc/conf.d/zmq.ini
|
|
- yes | pecl install imagick
|
|
- mysql -e 'create database update39_test;create database ab_test;create database db_test; create database ab_unitTests; create database db_unitTests;'
|
|
- sudo mysql -e "GRANT ALL PRIVILEGES ON ab_unitTests.* TO 'phraseaUnitTests'@'localhost' IDENTIFIED BY 'iWvGxPE8' WITH GRANT OPTION"
|
|
- sudo mysql -e "GRANT ALL PRIVILEGES ON db_unitTests.* TO 'phraseaUnitTests'@'localhost' IDENTIFIED BY 'iWvGxPE8' WITH GRANT OPTION"
|
|
- mysql -e 'SET @@global.sql_mode= "";'
|
|
- mysql -e 'SET @@global.max_allowed_packet= 33554432;'
|
|
- mysql -e 'SET @@global.wait_timeout= 999999;'
|
|
- git clone git://github.com/alchemy-fr/Phraseanet-Extension.git
|
|
- sh -c "cd Phraseanet-Extension && phpize && ./configure --quiet && make -j --quiet && sudo make install"
|
|
- echo "extension=phrasea2.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
|
|
- git clone git://github.com/alchemy-fr/Phraseanet-Indexer.git
|
|
- sh -c "cd Phraseanet-Indexer && autoreconf --force --install && ./configure --quiet && make -j --quiet && sudo make install"
|
|
|
|
php:
|
|
- 5.4
|
|
- 5.5
|
|
- 5.6
|
|
|
|
matrix:
|
|
fast_finish: true
|
|
allow_failures:
|
|
- php: 5.6
|
|
|
|
script:
|
|
- travis_retry composer install --dev --prefer-source -vvv
|
|
- travis_retry grunt install-assets -vvv
|
|
- bin/developer assets:compile-less
|
|
- bin/developer system:uninstall
|
|
- sh -c " if [ '$SETUP_MODE' = 'update' ]; then
|
|
bin/setup system:install --email=test@phraseanet.com --password=test --db-user=root --db-template=fr --db-password= --databox=db_test --appbox=ab_test --server-name=http://127.0.0.1 -y -v;
|
|
bin/developer ini:reset --email=test@phraseanet.com --password=test --run-patches -v;
|
|
fi"
|
|
- sh -c " if [ '$SETUP_MODE' = 'install' ]; then
|
|
bin/setup system:install --email=test@phraseanet.com --password=test --db-user=root --db-template=fr --db-password= --databox=db_test --appbox=ab_test --server-name=http://127.0.0.1 -y -v;
|
|
bin/developer ini:setup-tests-dbs -v;
|
|
fi"
|
|
- php resources/hudson/cleanupSubdefs.php
|
|
- bin/developer phraseanet:regenerate-sqlite
|
|
- ./node_modules/.bin/grunt test
|
|
- bin/phpunit
|