How to create Selenium Cucumber Project in Eclipse.

Author: neptune | 25th-May-2022
#Selenium

Let’s create Automation Project in Eclipse

Let’s consider this particular project where we will try automating the process of booking a flight ticket. 

Let’s get started and see how it’s done using Selenium.

First, divide the process into the various steps to understand working in brief of a project.




Steps in brief:

  1. We’ll start with initializing the browser driver and then log in to the web page

  2. Find the flight according to the user requirements

  3. Select a flight and book it

  4. Capture a screenshot of the confirmation page

Now let’s have a look at the steps involved in the creation of this project.


Step 1: Create a Workspace


Step 2: Create a Maven Project in the above workspace

Go to File-> Go to New-> Others -> Maven Project to create a new Maven Project.







Step 2: Add the dependencies to pom.xml file

Now add the dependencies to pom.xml file





Step 3: Create the packages

Create the packages under the src/main/java folder and the src/test/java folder and start writing the piece of code.



Step 4: Setup the TestRunner class





Step 5: Create features in SpiceJet.feature

Now create a feature in SpiceJet.feature file.





Step 6: Create features in SpiceJetStepDefs.java

In  SpiceJetStepDefs.java create the step definitions as per your features that you created in SpiceJet.feature.


That’s how we create a Maven Cucumber Project in Eclipse.


Thanks for Reading !!! 

If you have any questions let me know in the comment section.




anonymous | May 18, 2022, 12:18 a.m.

Very well explained 👍



Related Blogs
Automate Ticket Booking in SpiceJet from Delhi to Bengaluru using Selenium and Cucumber.
Author: neptune | 08th-Aug-2023
#Selenium
We are going to automate a ticket booking using Selenium WebDriver and Cucumber BDD...

Selenium, Cucumber, JUnit, TestNG dependencies for Selenium project.
Author: neptune | 02nd-Apr-2023
#Selenium #Testing
We guide you how to update the pom.xml file for Selenium Maven project...

5 Selenium Project Ideas & for Beginners in Automation Testing
Author: neptune | 30th-Mar-2023
#Selenium #Testing #Projects
In this article, we will discuss 5 interesting Selenium project ideas for beginners in automation testing...

How to use wait commands in Selenium WebDriver in Java ?
Author: neptune | 22nd-Feb-2022
#Selenium #Testing #Java
We are going to explore different types of waits in Selenium WebDriver. Implicit wait, Explicit wait, and Fluent wait with examples...

Top 50+ Selenium Interviews Questions 2023 based on Years of Experience
Author: neptune | 02nd-Apr-2023
#Selenium #Testing #Interview
Every interview difficulty is based on how many years of experience you have in that field. For the Selenium Automation Tester I have divided the question on the number of years of experience...

Top 10 Selenium Interview Questions with answers (2021).
Author: neptune | 02nd-Apr-2023
#Selenium #Interview
In this article I will cover top 10 Selenium interview questions...

Challenges faced in automating Web Applications using Selenium
Author: neptune | 02nd-Oct-2022
#Selenium #Testing
List of Challenges faced by testers using Selenium 1. Popup and Alert Handling, 2. Dynamic element Handling 3. Restricted to only Desktop Browsers Testing...

How to create a Selenium, Cucumber Automation project in Eclipse ?
Author: neptune | 02nd-Apr-2023
#Selenium #Testing
Problem Statement : Let’s consider this particular project where we will try automating the process of booking a flight ticket. Let’s get started and see how it’s done using Selenium...

20 TestNG Interview Questions
Author: neptune | 17th-Dec-2022
#Selenium #Interview
There is always more than one test or method in the class. If we do not prioritize these tests or methods, then the methods are selected alphabetically and executed while execution...

Getting started with Selenium WebDriver.
Author: neptune | 02nd-Apr-2023
#Selenium #Testing
In this blog I will give you an overview of Selenium WebDriver and Also discuss about advantages and disadvantages of Selenium WebDriver...

Why we use Robot Class in Automation Testing?
Author: neptune | 23rd-Aug-2022
#Selenium
Robot class is used to generate native system input events for the purpose of automation testing. It is used to perform mouse and keyboard events on windows applications or popups...

Top 10 Selenium Interview Questions.
Author: neptune | 02nd-Apr-2023
#Selenium #Interview
Locator is a command that tells Selenium IDE which GUI elements (like Text Box, Buttons, Check Boxes etc) we are going to use or perform some automation task...

How to send POST request using Rest Assured framework in Java ?
Author: neptune | 26th-Mar-2023
#Selenium #API
Rest Assured is a popular Java-based framework that is used for testing RESTful web services. It provides a simple and intuitive API for sending HTTP requests and validating the responses...

View More