Skip to content

Commit 54dd7fe

Browse files
committed
Merge pull request #97 from 66Ton99/1.2
[1.2] Fixed travis build & some improvements
2 parents 399e3f3 + ea25475 commit 54dd7fe

File tree

16 files changed

+186
-2362
lines changed

16 files changed

+186
-2362
lines changed

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,6 @@ vendor
33
composer.lock
44
composer.phar
55
build/*
6-
Tests/app/Resources/local_config.php
6+
Tests/app/Resources/local_config.php
7+
Resources/public/js/fp_js_validator.js
8+
phpunit.xml

.travis.yml

Lines changed: 31 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
language: php
22

3-
php: [5.3,5.4,5.5,5.6,7]
3+
php: [5.3,5.4,5.5,5.6]
44

55
env:
6-
- SF_VERSION='~2.3.0,>=2.3.18'
7-
- SF_VERSION='~2.4.0,>=2.4.8'
8-
- SF_VERSION='~2.5.0,>=2.5.2'
6+
- SF_VERSION='~2.3.0,>=2.3.19'
7+
- SF_VERSION='~2.4.0,>=2.4.9'
8+
- SF_VERSION='~2.5.0,>=2.5.3,<=2.5.4'
99

1010
before_script:
1111
- export WEB_FIXTURES_HOST=http://localhost/index.php
@@ -15,27 +15,41 @@ before_script:
1515
- sleep 4
1616

1717
- Tests/app/switch_sf_version.sh "$SF_VERSION"
18-
- composer require "symfony/symfony:${SF_VERSION}"
19-
- composer install -n
20-
- composer info -i
18+
- curl -sS https://getcomposer.org/installer | php
19+
- php -d memory_limit=-1 composer.phar require "symfony/symfony:${SF_VERSION}"
20+
- php -d memory_limit=-1 composer.phar install -n
21+
- php -d memory_limit=-1 composer.phar info -i
22+
23+
- Tests/app/console assets:install -v Tests/app || Tests/app/console assets:install -v Tests/app
24+
- Tests/app/console assetic:dump -v Tests/app
2125

22-
- Tests/app/console assets:install Tests/app
2326
- sudo chmod -R 0777 Tests/app/cache Tests/app/logs
24-
- sudo chmod 0777 Resources/public/js/fp_js_validator.js
27+
- sudo chmod 0777 Resources/public/js
2528
# just show the current directory tree
2629
- ls -R | grep ":$" | sed -e 's/:$//' -e 's/[^-][^\/]*\//--/g' -e 's/^/ /' -e 's/-/|/'
2730

2831
- sudo apt-get update > /dev/null
29-
- sudo apt-get install -y --force-yes apache2 libapache2-mod-php5 > /dev/null
30-
31-
- sudo sed -i -e "s,/var/www,$(pwd)/Tests/app,g" /etc/apache2/sites-available/default
32-
- sudo /etc/init.d/apache2 restart
33-
34-
- vendor/bin/selenium-server-standalone &> selenium.log &
32+
- sudo apt-get install -y --force-yes apache2 libapache2-mod-fastcgi > /dev/null
33+
# enable php-fpm
34+
- sudo cp ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.conf.default ~/.phpenv/versions/$(phpenv version-name)/etc/php-fpm.conf
35+
- sudo a2enmod rewrite actions fastcgi alias
36+
- echo "cgi.fix_pathinfo = 1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini
37+
- ~/.phpenv/versions/$(phpenv version-name)/sbin/php-fpm
38+
# configure apache virtual hosts
39+
- sudo cp -f Tests/app/Resources/travis-ci-apache /etc/apache2/sites-available/default
40+
- sudo sed -e "s?%TRAVIS_BUILD_DIR%?$(pwd)/Tests/app?g" --in-place /etc/apache2/sites-available/default
41+
- sudo /etc/init.d/apache2 restart || (sudo cat /var/log/apache2/error.log && exit 1)
42+
43+
- vendor/bin/selenium-server-standalone &> Tests/app/logs/selenium.log &
3544
- sleep 4
3645

37-
script: phpunit -v
46+
47+
script: ./vendor/bin/phpunit -v --debug
3848
#after_script:
3949
# - php vendor/bin/coveralls -v
4050
after_failure:
41-
- cat selenium.log
51+
- cat Tests/app/logs/selenium.log
52+
- cat Tests/app/logs/apache-access.log
53+
- cat Tests/app/logs/apache-error.log
54+
- cat Tests/app/logs/cgi.log
55+
- firefox-bin -v

0 commit comments

Comments
 (0)