Merge remote-tracking branch 'origin/master'

This commit is contained in:
Weblate 2016-01-25 10:55:08 +01:00
commit bc5370cad8
7 changed files with 39 additions and 29 deletions

View File

@ -10,7 +10,6 @@ php:
- "5.6"
- "5.5"
- hhvm
- nightly
sudo: false
@ -22,22 +21,23 @@ env:
- TESTSUITE_PASSWORD=root
- TESTSUITE_URL=http://127.0.0.1:8000
install:
- pip install --user codecov
- ./test/install-runkit
- ./test/install-browserstack
- composer install --dev --no-interaction
before_script:
- phpenv config-add test/php-noprofile.ini
- export PATH=~/.composer/vendor/bin/:$PATH
- mysql -uroot -e "CREATE DATABASE test"
- mysql -uroot < sql/create_tables.sql
- mysql -uroot -e "SET PASSWORD = PASSWORD('$TESTSUITE_PASSWORD')"
- composer install --dev --no-interaction
- pip install --user codecov
- if [ $TRAVIS_PHP_VERSION != "hhvm" ] ; then ./test/install-runkit ; fi
- if [ -n "$SELENIUM" ] ; then ./test/install-browserstack ; fi
- if [ -n "$SELENIUM" ] ; then php --server 127.0.0.1:8000 > php.log & fi
- if [ -n "$SELENIUM" ] ; then ~/browserstack/BrowserStackLocal -localIdentifier "travis-$TRAVIS_JOB_NUMBER" -onlyAutomate "$TESTSUITE_BROWSERSTACK_KEY" 127.0.0.1,8000,0 & fi
- ./test/start-local-server
script:
- ant clean
- ant locales
- if [ -z "$SELENIUM" ] ; then ant lint ; fi
- set -e;
if [ $TRAVIS_PHP_VERSION == "hhvm" ] ; then
ant phpunit-hhvm ;
@ -45,6 +45,7 @@ script:
if [ ! -z "$SELENIUM" ] ; then
ant phpunit-nocoverage ;
else
ant lint ;
ant phpunit ;
fi ;
fi
@ -59,8 +60,6 @@ matrix:
allow_failures:
- php: 5.6
env: PHPUNIT_ARGS="--group selenium" SELENIUM="yes"
- php: nightly
env: PHPUNIT_ARGS="--exclude-group selenium"
fast_finish: true
include:
- php: 5.6

View File

@ -1,6 +1,11 @@
#!/bin/sh
set -e
set -x
if [ -z "$SELENIUM" ] ; then
exit 0
fi
mkdir -p ~/browserstack
cd ~/browserstack

View File

@ -1,21 +1,12 @@
#!/bin/bash
if [ $TRAVIS_PHP_VERSION = "nightly" -o $TRAVIS_PHP_VERSION = "7.0" ] ; then
if [ "$TRAVIS_PHP_VERSION" = "nightly" -o "$TRAVIS_PHP_VERSION" = "hhvm" -o "$TRAVIS_PHP_VERSION" = "7.0" ] ; then
exit 0
fi
set -e
set -x
git clone --depth=100 git://github.com/zenovich/runkit.git
pecl install runkit
pushd runkit
git checkout c337393762d54cf6df305cf8e92dac3a162157f4
phpize
./configure
make
make install
popd
phpenv config-add test/travis.php.ini
phpenv config-add test/php-runkit.ini

3
test/php-noprofile.ini Normal file
View File

@ -0,0 +1,3 @@
; PHP configuration tweaks for tests on Travis
xdebug.profiler_enable=0

7
test/php-runkit.ini Normal file
View File

@ -0,0 +1,7 @@
; PHP configuration tweaks for tests on Travis
; Extension is automaticlaly enabled by PECL
; extension=runkit.so
; Enable override of internal functions
runkit.internal_override=1

11
test/start-local-server Executable file
View File

@ -0,0 +1,11 @@
#!/bin/sh
set -e
set -x
if [ -z "$SELENIUM" ] ; then
exit 0
fi
php --server 127.0.0.1:8000 > php.log &
~/browserstack/BrowserStackLocal -localIdentifier "travis-$TRAVIS_JOB_NUMBER" -onlyAutomate "$TESTSUITE_BROWSERSTACK_KEY" 127.0.0.1,8000,0 &

View File

@ -1,6 +0,0 @@
; PHP configuration tweaks for tests on Travis
; Load runkit and enabled override of internals
extension=runkit.so
runkit.internal_override=1
xdebug.profiler_enable=0