Thursday, 24 March 2016

Setting up Selenium Gradle project in Intellij IDEA

Gradle is one of the most popular build management systems in the Java world. Gradle is developed to eliminate the drawbacks in Ant and Maven. In this article, you will learn how you can set up a selenium project using Gradle in Intellij IDEA.

The tools you will need are -

  1. JDK - You can know more about JDK installation process in Windows on Softpost Java Tutorial
  2. Intellij IDEA IDE - Community Edition (It's free)
  3. Gradle (It's free) In latest versions of Intellij IDEA (15.0.4+) , Gradle comes built-in So you do not need to download it separately.
Below Images will guide you through the steps for creating the Selenium-Gradle project.

Step 1 - Click on New Project menu in Intellij IDEA and then select Gradle Project

Step 2 - Types in the Group Id and Artifact Id for your project

Step 3 - Provide Gradle Settings

Step 4 - Type Project Name

Step 5 - Gradle project directory layout

Step 6 - Build.Gradle File and Selenium dependency

Step 7 - Write and execute Selenium tests

Step 8 - Executing gradle tasks

What do you think on above selenium topic. Please provide your inputs and comments. You can write to me at

1 comment:

  1. Thanks for your blog. It was helpful. But I understood only till Step 7. How and where did you see test gradle task? I am using Selenium Webdriver + Gradle + Intellij + Java + Junit. I have setup the project and its running if I run the individual tests. However I want to use gradle tasks. Can you please elaborate Step 8?


Buy Best Selenium Books