Selenium test on CircleCI 1.0

Hello everyone,
I’m trying to build (on CircleCI 1.0) a very old Rails (2.0.2) application using Selenium.
I’m able to run the test suite locally (on a Ubuntu 16.04 machine) with the following steps:

sudo apt-get install xvfb firefox
Xvfb :99 -ac &
export DISPLAY=:99
bundle exec script/server -p 3003 -e test -d
bundle exec rake test:acceptance

From my understanding, on CircleCI 1.0 Xvfb works out of the box so here my circle.yml file

machine:
  ruby:
    version: 1.8.7-p370
  environment:
    RAILS_ENV: test

dependencies:
  pre:
    - sudo apt-get install firefox
  override:
    - gem install bundler
    - bundle check --path=vendor/bundle || bundle install --path=vendor/bundle

database:
  override:
    - mv config/database.ci.yml config/database.yml
    - bundle exec rake db:create db:schema:load --trace

test:
  pre:
    - bundle exec script/server -p 3003 -e test -d
  override:
    - bundle exec rake test:acceptance

However, the tests fail, and it seems to me the issue is related to the browser since the rake task exists right after starting.

Am I missing anything here? Should I add some extra step to properly run Xvfb and firefox?

Thanks