How to execute cucumber feature file in Parallel using TestNG | Selenium Java | TestNG

Published: 13 March 2021
on channel: Maximum Automation
9,628
115

In this video we are going to see that how to execute cucumber features through testng.xml file.
To add the file right click on the project and then add a new xml file. Provide the name of the file as testng.xml.
Please make sure that you are adding the file at root level of the project.


after that add below content in your testng.xm file



#?xml version="1.0" encoding="UTF-8"?#
!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" #
#suite name="My TestSuite" parallel="classes"#
#test name="BookVerification"#
#classes#
#class name="runner.runner"##/class#
#class name="runner.runner2"##/class#
#/classes#
#/test#
#/suite#


Class name is the runner class where we have used the testng annotations. You can update the class name based on your framework. After that run the test using testng.xml.
Right click on the testng xml file and then run it as testng suite..
Then you can see that the scenarios will be running in parallel.


*********Please comment in case of any query************


Also please watch other videos as well.

Add Java properties configuration file in framework - Selenium Java -    • Configuration file in automation fram...  

How to setup selenium grid in docker :    • How to setup Selenium Grid in Docker ...  

Log4J2 - Logging in Java Framework :    • Video  

Selenium with Java - Create Junit Cucumber Project :    • Video  

Selenium - Debug/Run Script on Existing Browser :    • Selenium | Debug/Run Script on Existi...  

Selenium with Java - Extent Report - Part1 :    • Selenium with Java | Extent Report 5 ...  

Selenium - WebDriver Manager :    • Selenium | WebDriver Manager | Stop d...  

Parallel Execution - Cucumber - Junit :    • Parallel Execution | Cucumber | Junit  

Selenium with Java - Cucumber Html Report :    • Selenium with Java | Cucumber Html Re...  

Selenium with Java - Integrate TestNG with Cucumber -    • Video  

Selenium with C# - Klov Report :    • Selenium with C# | Klov Report Server  

Selenium with C# - Extent Report :    • Selenium with C# | Extent Report  

Selenium with C# - Create Project to automate test (Selenium + Specflow ) :    • Video  

Selenium with C# - Parallel Execution and Screenshot :    • Video  

Selenium with C# - All about feature files :    • Video  

Selenium with C# - Specflow - External Bindings :    • Selenium C# | Specflow | External Bin...  

Selenium with C# Working with Excel - Part 1 :    • Video  

Selenium C# - Visual Studio Code :    • Selenium C# | Visual Studio Code | No...  
n

How to execute cucumber feature file in Parallel using TestNG | Selenium Java | TestNG -    • How to execute cucumber feature file ...  


Watch video How to execute cucumber feature file in Parallel using TestNG | Selenium Java | TestNG online without registration, duration hours minute second in high quality. This video was added by user Maximum Automation 13 March 2021, don't forget to share it with your friends and acquaintances, it has been viewed on our site 9,628 once and liked it 115 people.