language: ruby
sudo: required
rvm:
  - 2.2
  - 2.3
  - 2.4
  - 2.5

before_install:
  # work around https://github.com/travis-ci/travis-ci/issues/8969
  - travis_retry gem update --system
install:
  - sudo apt-get update -qq
  - sudo apt-get install libpcap-dev -qq
  - bundle install --path vendor/bundle --jobs=3 --retry=3
before_script:
  - openssl version
  - ruby -ropenssl -e 'puts OpenSSL::VERSION'
script:
  - bundle exec rake
  - rvmsudo bundle exec rake spec:sudo

language: ruby
sudo: required
rvm:
  - 2.2
  - 2.3
  - 2.4
  - 2.5

matrix:
  # allow 2.5 to fail until Travis CI is fixed.
  # See travis-ci/travis-ci#8969
  allow_failures:
  - rvm: 2.5

before_install:
  # work around https://github.com/travis-ci/travis-ci/issues/8969
  - travis_retry gem update --system
install:
  - sudo apt-get update -qq
  - sudo apt-get install libpcap-dev -qq
  - bundle install --path vendor/bundle --jobs=3 --retry=3
before_script:
  - openssl version
  - ruby -ropenssl -e 'puts OpenSSL::VERSION'
script:
  - bundle exec rake
  - rvmsudo bundle exec rake spec:sudo

Allow 2.5 to fail until Travis CI bug is fixed.
Allow 2.5 to fail until Travis CI bug is fixed.

See travis-ci/travis-ci#8969
