From c8617bacea5a8fcb3c8d97ad3de7ebb7a56558e9 Mon Sep 17 00:00:00 2001 From: Alexey Andreev Date: Sat, 22 Apr 2017 14:14:50 +0300 Subject: [PATCH] Use another approach to install chrome --- .travis.yml | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/.travis.yml b/.travis.yml index 05bb278c4..d3c611872 100644 --- a/.travis.yml +++ b/.travis.yml @@ -15,11 +15,12 @@ branches: before_install: - nvm install 7 - - CHROMIUM_BUILD=466537 - - mkdir -p $HOME/.chromium_dist/ - - CHROMIUM_ZIP=$HOME/.chromium_dist/chromium-$CHROMIUM_BUILD.zip - - if [ ! -f $CHROMIUM_ZIP ]; then wget https://www.googleapis.com/download/storage/v1/b/chromium-browser-snapshots/o/Linux_x64%2F$CHROMIUM_BUILD%2Fchrome-linux.zip?alt=media -O $CHROMIUM_ZIP; fi - - unzip -q $CHROMIUM_ZIP + - wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb -O .chromium_dist + - export DISPLAY=:99.0 + - sudo dpkg -i google-chrome*.deb + - export CHROME_BIN=/usr/bin/google-chrome + - export DISPLAY=:99.0 + - sh -e /etc/init.d/xvfb start - OLD_VERSION=`mvn help:evaluate -Dexpression=project.version 2>/dev/null | grep -Ev "(^\[|Download\w+:)"` - NEW_VERSION=${OLD_VERSION%-SNAPSHOT}-dev-`printf %d $TRAVIS_BUILD_NUMBER` - echo "Building version $NEW_VERSION" @@ -34,15 +35,15 @@ install: - popd script: - - mvn -e test #-P \!htmlUnit + - mvn -e test -P \!htmlUnit - BASE_PATH=`pwd` - #- pushd tests/src/test/js - #- $BASE_PATH/chrome-linux/chrome --headless --remote-debugging-port=9222 --disable-gpu about:blank & - #- CHROME_PID=$! - #- node start.js $BASE_PATH/tests/target/js-tests - #- node start.js $BASE_PATH/html4j/target/js-tests - #- kill $CHROME_PID - #- popd + - pushd tests/src/test/js + - $CHROME_BIN --remote-debugging-port=9222 --disable-gpu about:blank & + - CHROME_PID=$! + - node start.js $BASE_PATH/tests/target/js-tests + - node start.js $BASE_PATH/html4j/target/js-tests + - kill $CHROME_PID + - popd after_success: > if [[ "${TRAVIS_PULL_REQUEST:-unknown}" == "false" && $TRAVIS_BRANCH == dev-* ]] ; then