language: node_js
node_js:
    - "lts/*"
sudo: false
addons:
    chrome: stable
    firefox: latest-esr

before_install:
    - npm install grunt-cli -g

before_script:
    - export DISPLAY=:99.0
    - sh -e /etc/init.d/xvfb start
    - sleep 3 # give xvfb some time to start

script:
    - grunt ci

branches:
    only:
        - develop

language: node_js
node_js:
    - "lts/*"
sudo: false
addons:
    chrome: stable
    firefox: latest-esr

before_install:
    - npm install grunt-cli -g

script:
    - xvfb-run grunt ci

branches:
    only:
        - develop

Use xvfb-run for invoking xvfb
Use xvfb-run for invoking xvfb
