os:
- osx
- linux
osx_image: xcode8
addons:
  apt:
    packages:
      - xvfb
language: node_js
node_js:
  - "6"
  - "8"
  - "10"

matrix:
  fast_finish: true
  include:
    - os: osx
      node_js: "8"
    - os: linux
      node_js: "8"
      env: BROWSER_TESTS=1 SAUCE_USERNAME=testem-ci SAUCE_ACCESS_KEY=1f00979e-0252-4d69-98ff-f6c85d1a746b
  exclude:
    - os: osx
sudo: false
before_install:
  - if [ $TRAVIS_OS_NAME == "osx" ]; then
      brew update;
      brew tap homebrew/cask;
      brew cask install phantomjs;
    fi
  - npm config set spin false
install:
  - export DISPLAY=':99.0'
  - Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
  - travis_retry npm install
before_script:
  - if [ $TRAVIS_OS_NAME == "linux" ] && [ $TRAVIS_NODE_VERSION == "4" ]; then
      npm run lint;
    fi
script:
  - npm run test
  - npm run integration

os:
- osx
- linux
osx_image: xcode8
addons:
  apt:
    packages:
      - xvfb
      - libgconf-2-4
language: node_js
node_js:
  - "6"
  - "8"
  - "10"

matrix:
  fast_finish: true
  include:
    - os: osx
      node_js: "8"
    - os: linux
      node_js: "8"
      env: BROWSER_TESTS=1 SAUCE_USERNAME=testem-ci SAUCE_ACCESS_KEY=1f00979e-0252-4d69-98ff-f6c85d1a746b
  exclude:
    - os: osx
sudo: false
before_install:
  - if [ $TRAVIS_OS_NAME == "osx" ]; then
      brew update;
      brew tap homebrew/cask;
      brew cask install phantomjs;
    fi
  - npm config set spin false
install:
  - export DISPLAY=':99.0'
  - Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
  - travis_retry npm install
before_script:
  - if [ $TRAVIS_OS_NAME == "linux" ] && [ $TRAVIS_NODE_VERSION == "4" ]; then
      npm run lint;
    fi
script:
  - npm run test
  - npm run integration

Add libgconf-2-4 to Travis to get Electron running in tests
Add libgconf-2-4 to Travis to get Electron running in tests
