2016-11-30 16:47:00 +00:00
|
|
|
sudo: true
|
2015-05-24 19:32:32 +00:00
|
|
|
language: php
|
2016-06-27 19:55:16 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
global:
|
|
|
|
- RUN_PHPCS="no"
|
|
|
|
|
2015-07-22 14:24:31 +00:00
|
|
|
matrix:
|
2016-06-27 19:55:16 +00:00
|
|
|
fast_finish: true
|
|
|
|
include:
|
2016-11-30 16:47:00 +00:00
|
|
|
- php: 5.5
|
|
|
|
- php: 5.6
|
|
|
|
env: RUN_PHPCS="yes"
|
2016-05-21 19:55:51 +00:00
|
|
|
- php: 7.0
|
2016-11-30 16:47:00 +00:00
|
|
|
sudo: true
|
|
|
|
addons:
|
|
|
|
firefox: "47.0.1"
|
|
|
|
- php: 7.1
|
|
|
|
- php: hhvm
|
|
|
|
sudo: true
|
|
|
|
dist: trusty
|
|
|
|
group: edge # Until the next stable image update sometime after 2016-12-01
|
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages:
|
|
|
|
- mysql-server-5.6
|
|
|
|
- mysql-client-core-5.6
|
|
|
|
- mysql-client-5.6
|
|
|
|
services:
|
|
|
|
- mysql
|
|
|
|
- postgresql
|
|
|
|
allow_failures:
|
|
|
|
- php: hhvm
|
2016-06-27 19:55:16 +00:00
|
|
|
|
2015-05-24 19:32:32 +00:00
|
|
|
before_script:
|
2016-08-15 11:52:01 +00:00
|
|
|
# Forcing localhost in hosts file
|
|
|
|
- sudo sed -i '1s/^/127.0.0.1 localhost\n/' /etc/hosts
|
2015-05-24 19:32:32 +00:00
|
|
|
- sudo apt-get update -qq
|
2016-07-31 07:33:59 +00:00
|
|
|
- sudo apt-get install -y --force-yes apache2 libapache2-mod-fastcgi > /dev/null
|
2015-10-30 09:43:37 +00:00
|
|
|
- sudo mkdir $(pwd)/.run
|
2016-07-31 07:33:59 +00:00
|
|
|
- chmod a+x tests/travis-php-fpm.sh
|
|
|
|
- sudo ./tests/travis-php-fpm.sh $USER $(phpenv version-name)
|
2015-10-30 09:43:37 +00:00
|
|
|
- sudo a2enmod rewrite actions fastcgi alias
|
|
|
|
- echo "cgi.fix_pathinfo = 1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
|
|
|
|
- ~/.phpenv/versions/$(phpenv version-name)/sbin/php-fpm
|
|
|
|
- sudo cp -f tests/travis-ci-apache.conf /etc/apache2/sites-available/default
|
|
|
|
- sudo sed -e "s?%TRAVIS_BUILD_DIR%?$(pwd)?g" --in-place /etc/apache2/sites-available/default
|
2016-07-31 07:33:59 +00:00
|
|
|
- sudo sed -e "s?%PHPVERSION%?${TRAVIS_PHP_VERSION:0:1}?g" --in-place /etc/apache2/sites-available/default
|
2015-10-30 09:43:37 +00:00
|
|
|
- git submodule update --init --recursive
|
|
|
|
- sudo service apache2 restart
|
2015-05-24 19:32:32 +00:00
|
|
|
# Xvfb
|
|
|
|
- "export DISPLAY=:99.0"
|
|
|
|
- "sh -e /etc/init.d/xvfb start"
|
|
|
|
- sleep 3 # give xvfb some time to start
|
|
|
|
# Fluxbox
|
|
|
|
- sudo apt-get install fluxbox -y --force-yes
|
|
|
|
- fluxbox &
|
|
|
|
- sleep 3 # give fluxbox some time to start
|
2015-10-30 09:43:37 +00:00
|
|
|
# Composer
|
2015-09-30 17:29:14 +00:00
|
|
|
- composer install
|
2015-05-24 19:32:32 +00:00
|
|
|
|
|
|
|
script:
|
2015-11-01 07:44:16 +00:00
|
|
|
# Build
|
2016-02-01 12:36:56 +00:00
|
|
|
- mv jorobo.dist.ini jorobo.ini
|
2015-11-01 07:44:16 +00:00
|
|
|
- vendor/bin/robo build
|
2016-06-27 19:55:16 +00:00
|
|
|
# System tests (Codeception)
|
2015-05-24 19:32:32 +00:00
|
|
|
- mv tests/acceptance.suite.dist.yml tests/acceptance.suite.yml
|
2015-11-01 12:09:58 +00:00
|
|
|
- vendor/bin/robo run:tests --use-htaccess
|
2016-06-27 19:55:16 +00:00
|
|
|
# Run phpcs on PHP 5.6 against weblinks source
|
|
|
|
- if [[ $RUN_PHPCS == "yes" ]]; then vendor/bin/phpcs --report=full --extensions=php -p --standard=tests/joomla-cms3/build/phpcs/Joomla ./src; fi
|