Skip to content

Commit

Permalink
Upgrade PhantomJS to 2.x on Travis
Browse files Browse the repository at this point in the history
- Fixes #60
  • Loading branch information
jhedstrom committed Nov 10, 2016
1 parent 78e52c3 commit 8110ea2
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,19 @@ mysql:
username: root
encoding: utf8

before_install:
- cd ..
# Upgrade PhantomJS to 2.x.
# @see https://github.com/travis-ci/travis-ci/issues/3225
# @see https://github.com/testdouble/present/commit/461ac72cdcfc4e87d84711550a638fbc12154567
- "export PHANTOMJS_VERSION=2.1.1"
- "export PATH=$PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64/bin:$PATH"
- "if [ $(phantomjs --version) != '$PHANTOMJS_VERSION' ]; then rm -rf $PWD/travis_phantomjs; mkdir -p $PWD/travis_phantomjs; fi"
- "if [ $(phantomjs --version) != '$PHANTOMJS_VERSION' ]; then wget https://github.com/Medium/phantomjs/releases/download/v$PHANTOMJS_VERSION/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -O $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2; fi"
- "if [ $(phantomjs --version) != '$PHANTOMJS_VERSION' ]; then tar -xvf $PWD/travis_phantomjs/phantomjs-$PHANTOMJS_VERSION-linux-x86_64.tar.bz2 -C $PWD/travis_phantomjs; fi"
- "phantomjs --version"
- cd -

before_script:
# Remove Xdebug as we don't need it and it causes "PHP Fatal error: Maximum
# function nesting level of '256' reached."
Expand Down Expand Up @@ -70,6 +83,9 @@ before_script:
# Export web server URL for browser tests.
- export SIMPLETEST_BASE_URL=http://localhost:8888

# Start PhantomJS
- phantomjs --ssl-protocol=any --ignore-ssl-errors=true ./vendor/jcalderonzumba/gastonjs/src/Client/main.js 8510 1024 768 2>&1 >> /dev/null &

script:
# Coding standards.
- $HOME/.composer/vendor/bin/phpcs --report=full --standard=Drupal $TESTDIR
Expand Down

0 comments on commit 8110ea2

Please sign in to comment.