Skip to content

Commit

Permalink
try fixing travis (#8200)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tlazypanda authored Jul 29, 2020
1 parent 919bf2b commit d855ffb
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
5 changes: 4 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ services:

addons:
mariadb: '10.2'
chrome: stable

cache:
directories:
Expand All @@ -28,7 +29,9 @@ env:
- RAILS_SYSTEM_TESTING_SCREENSHOT=simple

before_install:
- sudo wget https://chromedriver.storage.googleapis.com/73.0.3683.68/chromedriver_linux64.zip
- CHROME_MAIN_VERSION=`google-chrome-stable --version | sed -E 's/(^Google Chrome |\.[0-9]+ )//g'`
- CHROMEDRIVER_VERSION=`curl -s "https://chromedriver.storage.googleapis.com/LATEST_RELEASE_$CHROME_MAIN_VERSION"`
- sudo wget https://chromedriver.storage.googleapis.com/${CHROMEDRIVER_VERSION}/chromedriver_linux64.zip
- sudo unzip chromedriver_linux64.zip -d /usr/local/bin/
- sudo chmod +x /usr/local/bin/chromedriver
- google-chrome-stable --headless --disable-gpu --remote-debugging-port=9222 http://localhost &
Expand Down
4 changes: 2 additions & 2 deletions test/application_system_test_case.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
require "test_helper"

class ApplicationSystemTestCase < ActionDispatch::SystemTestCase
chromeOptions = %w(--headless --disable-gpu --no-sandbox --remote-debugging-port=9222)
caps = Selenium::WebDriver::Remote::Capabilities.chrome("chromeOptions" => {"args" => chromeOptions})
chromeOptions = %w(no-sandbox disable-dev-shm-usage headless disable-gpu remote-debugging-port=9222)
caps = Selenium::WebDriver::Remote::Capabilities.chrome("goog:chromeOptions" => {"args" => chromeOptions})
driven_by :selenium, using: :chrome, screen_size: [1400, 1400], options: { desired_capabilities: caps }

# https://web.archive.org/web/20170730200309/http://blog.paulrugelhiatt.com/rails/testing/capybara/dropzonejs/2014/12/29/test-dropzonejs-file-uploads-with-capybara.html
Expand Down

0 comments on commit d855ffb

Please sign in to comment.