Prerequisites (Selenium Java)

< Back

Install Prerequisites

Here we’ll be installing all the prerequisites you need to get started with Selenium test automation in Java.

  1. Create a free TestModeller.io account
  2. Install the Java Development Kit – NOTE: The example framework targets Java 8 only out of the box.
    • Download it from here and follow the associated instructions
  3. Install an IDE for editing Java code – We like to use IntelliJ editor, but Eclipse is also fine.
    • Download IntelliJ from here
  4. Install ChromeDriver (this needs to match the version of chrome you will be executing your tests on) and make sure you add it to your system PATH.
  5. Install Maven – this is used to manage the build process of our automation framework.
    • You can download the Maven binary Zip file from here.
    • There are instructions here. Make sure you add it to your system PATH
  6. Download our example Java framework (if you don’t have your own).
    • You can download the framework from out GitHub repo here.

Test It’s Working

Make sure to restart the Terminal or Command line prompt to load the new environment variables.

  1. Run mvn -v. You should see something like below:
  2. Run sample automation library
    • Navigate to the Java framework directory (this should contain the pom.xml file).
    • Run mvn test. You should see some basic login tests execute against the Magento webstore.
 Tip
Execution on other web browsers…

In this tutorial we will be executing our tests on Google Chrome. You can use Firefox driver and Internet Explorer driver available from the Selenium website if you wish to interchange chrome for either of these browsers and beyond.

Previous Welcome Selenium (Java)
Next Configuration (Java)
Table of Contents