Set up a Selenium project environment


This recipe will describe how we can set up our project environment. We will use Eclipse as development environment as further examples will be written in Java, but we can use any IDE which support our favorite programming language, preferable a strong type language. (like: ActionScript 3, C++, C#, Java, Python, OCaml, Vala) A strong type language sets the boundaries where we have to behave in, other than a dynamic type language(like: BASIC, JavaScript, Perl, PHP, Rexx).


Make sure you have download the latest stable TestNG library from Next thing is to make sure that we have the latest stable version of the Selenium library from


  1. Create a new Java project in Eclipse
  2. Create two separate folders, named tests and src
  3. Import the TestNG library. By opening the context menu on the project, and select Properties > Java Build Path > Libraries > Add External JARs
  4. Import the Selenium library in the same way as described above

What has been done

We have create our project structure, by importing the libraries and creating two separate folders. In the src folder we will create the website abstraction and in the tests folder we will create our test scripts.

Tip 1: The latest Selenium releases comes with a lot of additional libraries which are very useful and can be found in the libs folder.

One thought on “Set up a Selenium project environment”

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.