Make Travis use the most recent Chromedriver

This commit is contained in:
Kamil Kokot 2017-12-27 13:08:42 +01:00
parent a3f488c9f1
commit 17c20087ed
No known key found for this signature in database
GPG key ID: 7BD76F7054D93C89
2 changed files with 3 additions and 4 deletions

View file

@ -1,7 +1,6 @@
language: php
dist: trusty
group: deprecated-2017Q4
env:
global:

View file

@ -8,8 +8,8 @@ prepare_for_behat_with_js() {
run_command "export DISPLAY=:99"
# Download and configure ChromeDriver
if [ ! -f $SYLIUS_CACHE_DIR/chromedriver ]; then
run_command "curl http://chromedriver.storage.googleapis.com/2.30/chromedriver_linux64.zip > chromedriver.zip"
if [ ! -f $SYLIUS_CACHE_DIR/chromedriver ] || [ "$($SYLIUS_CACHE_DIR/chromedriver --version | grep -c 2.34)" = "0" ]; then
run_command "curl http://chromedriver.storage.googleapis.com/2.34/chromedriver_linux64.zip > chromedriver.zip"
run_command "unzip chromedriver.zip"
run_command "chmod +x chromedriver"
run_command "mv chromedriver $SYLIUS_CACHE_DIR"
@ -19,7 +19,7 @@ prepare_for_behat_with_js() {
run_command "$SYLIUS_CACHE_DIR/chromedriver > /dev/null 2>&1 &"
# Download and configure Selenium
if [ ! -f $SYLIUS_CACHE_DIR/selenium.jar ]; then
if [ ! -f $SYLIUS_CACHE_DIR/selenium.jar ] || [ "$(java -jar $SYLIUS_CACHE_DIR/selenium.jar --version | grep -c 3.4.0)" = "0" ]; then
run_command "curl http://selenium-release.storage.googleapis.com/3.4/selenium-server-standalone-3.4.0.jar > selenium.jar"
run_command "mv selenium.jar $SYLIUS_CACHE_DIR"
fi