TestingSelenium » History » Revision 4

« Previous | Revision 4/37 (diff) | Next »
Andreas Kohlbecker, 03/15/2011 11:46 AM

Functional Website Testing with Selenium

We will use Jenkins CI": in order to run "SeleniumHQ tests headlessly on a Debian server.

Install SeleniumHQ

The Selenium Server is needed in order to run either Selenium RC style scripts or Remote Selenium Webdriver ones.

  1. download the Selenium Standalone Server from

Install xvfb

The following installation instructions have been copied from the great guidance on this topic, though we found that we need to install additional packages we decided repeat and extend this guidance here.

To install xvfb:

sudo apt-get install xvfb apt-get libgl1-mesa-dri x11-utils

And then to check everything’s OK:

Xvfb :99

Where :99 is the display number. We set it to 99 to avoid any conflict with other displays, should they be attached. The command line should just hang without any comments until you press CTRL-C to close.

Install iceweasel (firefox)

To install iceweasel, which is currently the debian version of firefox:

sudo apt-get install iceweasel

And then, once you’re installed, to test that it works OK.

  1. Start Xvfb in one window as above,

  2. then in a second terminal window:

export DISPLAY=:99

you should see nothing – firefox should just sit there until you CTRL+C.

The “export DISPLAY=:99″ line is telling firefox to use display # 99, which we started above.

we want to take take a screenshot in order to check that everything is ok. We will use ImagMagick for this:

see also

apt-get install imagemagick

Updated by Andreas Kohlbecker about 11 years ago · 4 revisions