1
0
Fork 0
mirror of https://github.com/teamcapybara/capybara.git synced 2022-11-09 12:08:07 -05:00
teamcapybara--capybara/.travis.yml
2018-05-14 13:17:06 -07:00

104 lines
2.4 KiB
YAML

language: ruby
sudo: required
dist: trusty
services:
- docker
rvm:
- 2.5.1
- 2.3.6
- jruby-9.1.16.0
gemfile:
- Gemfile
env:
global:
- NOKOGIRI_USE_SYSTEM_LIBRARIES=true
- JAVA_OPTS=-Djava.security.egd=file:/dev/urandom
# matrix:
# - WINDOW_TEST=true
addons:
apt:
sources:
- google-chrome
packages:
- google-chrome-stable
- google-chrome-beta
- awesome
cache:
bundler: true
directories:
- ~/.webdrivers
matrix:
include:
- gemfile: Gemfile
rvm: 2.5.1
env: CAPYBARA_CHROME_REMOTE=true
- gemfile: gemfiles/Gemfile.rspec-34
rvm: 2.3.6
env: CAPYBARA_FF=true
addons:
firefox: latest
apt:
packages:
- awesome
- gemfile: Gemfile
rvm: 2.5.1
env: HEADLESS=true
- gemfile: gemfiles/Gemfile.beta-versions
rvm: 2.5.1
env: CAPYBARA_FF=true
addons:
firefox: latest-beta
apt:
packages:
- awesome
- gemfile: gemfiles/Gemfile.edge-marionette
rvm: ruby-head
env: CAPYBARA_FF=true
addons:
firefox: latest-nightly
apt:
packages:
- awesome
- gemfile: Gemfile
rvm: 2.4.3
env: CAPYBARA_FF=true HEADLESS=true
addons:
firefox: latest
allow_failures:
- gemfile: gemfiles/Gemfile.beta-versions
- gemfile: gemfiles/Gemfile.edge-marionette
- env: CAPYBARA_CHROME_REMOTE=true
before_install:
- gem update --system
- gem install bundler
- if [[ $BUNDLE_GEMFILE =~ Gemfile.edge-marionette$ ]]; then
pushd ..;
git clone --depth 1 https://github.com/SeleniumHQ/selenium.git;
cd selenium; ./go //rb:gem:build;
popd;
bundle config local.selenium-webdriver ../selenium/build/rb;
fi
before_script:
- if [[ -z $HEADLESS && -z $CAPYBARA_CHROME_REMOTE ]]; then
export DISPLAY=:99.0;
sh -e /etc/init.d/xvfb start;
sleep 1;
mkdir -p ~/.config/awesome;
echo "require('awful'); tags = {}; tags[1] = awful.tag({'name'})" > ~/.config/awesome/rc.lua;
awesome &
fi
- if [[ $CAPYBARA_CHROME_REMOTE = true ]]; then
docker-compose up -d selenium
TIMEOUT=10
until wget --spider http://localhost:4444 > /dev/null 2>&1 || [ $TIMEOUT -eq 0 ]; do
echo "Waiting for selenium server, $((TIMEOUT--)) remaining attempts...";
sleep 1;
done
fi
script: "bundle exec rake travis"