No video

Selenium Cucumber BDD Framework with Java and TestNG - Login Test

In this video, We will automating a login page of "www.saucedemo...." application using Behavior Driven Development approach(also known as BDD) where in we will be writing login scenario in Cucumber feature file,and step definition(backend code/glue code) for the feature file, And will be writing a TestRunner class using TestNG.
And also analyze Html/JSON/XML reports at the end of the test execution.
#bddevelopment framework: Behavior Driven Development is a software development approach that allows the tester/business analyst to create test cases in simple text language (English). The simple language used in the scenarios helps even non-technical team members to understand what is going on in the software project.
#cucumber #integration with #selenium :
Cucumber can be integrated with Selenium, a popular web testing framework, to create an efficient and maintainable automated testing solution. Here's how you can use the Cucumber BDD framework in conjunction with Selenium:
Setup Environment:
Install Java Development Kit (JDK) and set up the environment variables.
Set up your preferred Integrated Development Environment (IDE), like Eclipse or IntelliJ.
Create a #Maven #Project:
Create a new Maven project in your chosen IDE. Maven helps manage dependencies and project structure.
Add Dependencies:
In your pom.xml file (Maven's configuration file), add dependencies for Cucumber, Selenium, and any other required libraries.
#CreateFeatureFiles:
Create feature files with scenarios in Gherkin syntax. These files will define the behavior you want to test.
Write #StepDefinitions:
Create step definition files for the steps in your feature files. These step definitions should map Gherkin steps to actual Selenium automation code.
Implement the methods that perform actions using Selenium WebDriver, such as clicking buttons, filling forms, navigating pages, etc.
#GlueCode
Cucumber relies on a "glue" layer to connect feature files with step definitions. Configure the location of your step definition files in the test runner.
#RunTests #TestRunner
Execute your tests by running the test runner class.
Cucumber will read the #featurefiles , match steps to #stepdefinitions, and execute the corresponding #Seleniumautomationcode
Reference URL(s):
sdetadda.blogs...
cucumber.io/
www.saucedemo....
www.selenium.dev/
Playlists in this channel:
Playwright with Java script [2023 latest] - End to end - By SDET Adda for QA Automation: • Playwright with Java s...
TestNG + Selenium 4 Tutorial -2022/2023 🔥🔥🔥: • TestNG + Selenium 4 Tu...
Selenium webdriver issues and solutions: • Selenium webdriver iss...
Basic Linux (UNIX) Commands with Shell Scripting Tutorial for Testers [2023]: • Linux and Bash Scripti...
Top 100 Java programs for QA testing Interviews: • Top 100 Java programs ...
I hope you have liked the explanation and learned from this video. 🙏 Please share my videos and subscribe to my channel 🔔 , also help your friends in learning the best by suggesting this channel.

Пікірлер: 51

  • @testing24x7
    @testing24x711 ай бұрын

    It is step by step and very much understandable.Many thanks for your efforts onto this. Please upload full series on cucumber with POM. Thanks again!

  • @sdetadda

    @sdetadda

    11 ай бұрын

    Sure I will

  • @22kusum
    @22kusum3 ай бұрын

    Very nice Lab with easy to understand Cucumber BDD Login scenarios.....practiced along with it , very good learning!!!!!

  • @prikalpanda7864
    @prikalpanda786411 ай бұрын

    Good explanation, Thanks a lot.

  • @sdetadda

    @sdetadda

    11 ай бұрын

    Glad it was helpful!

  • @TestingUnlimited
    @TestingUnlimited9 ай бұрын

    Step by step explanation. Thank you for posting it.

  • @nikhithamadishetti4953
    @nikhithamadishetti49532 ай бұрын

    Thank you for step by step explanation of adding dependencies, i have resolved exception error which am facing due to incrt dependencies

  • @riyashukla1717
    @riyashukla171711 ай бұрын

    Well explained sir ..plz upload more vedio for cucumber

  • @Akash07ify
    @Akash07ify2 ай бұрын

    You made my life so easy thank you 😊

  • @ganeshmuthu7275
    @ganeshmuthu72754 ай бұрын

    Great explanation 🎉

  • @praveenalgudkar764
    @praveenalgudkar7649 ай бұрын

    very much understandable sir happy to watch and easy getting all those things make full version of on this topic then it will help us bit more for feature .thank you

  • @poojashinde9494
    @poojashinde94943 ай бұрын

    Nice explanation Thank u so much

  • @PhaniPavanKumarChelluboina
    @PhaniPavanKumarChelluboina4 күн бұрын

    Hi @Raghav, I would like to learn this course. But, I got confused with the set up for this Environment in Eclipse. Do you have any information regarding, which jar files we need to import, maven dependencies, and anything else. Could you please share the information regarding my doubt.

  • @sdetadda

    @sdetadda

    4 күн бұрын

    Please clone the repository from git@gitlab.com:sdetadda/RaghavendraMishra.git to access the required POM.xml file

  • @AmarKadam-zg6wh
    @AmarKadam-zg6whАй бұрын

    Many thanks. Lots of love

  • @sdetadda

    @sdetadda

    14 күн бұрын

    You're most welcome.

  • @sahil98031
    @sahil9803111 ай бұрын

    When integrating Cucumber with the TestNG framework, do you not lose the annotations and other capabilities of TestNG? Because you can just create this framework using JUnit instead of TestNG. Or am I missing something? Please feel free to educate me. Great video as always :).

  • @sdetadda

    @sdetadda

    11 ай бұрын

    Both junit and testng would eventually serve the same purpose when used with cucumber.

  • @DailyDoseofEntertainment-l7e
    @DailyDoseofEntertainment-l7e8 ай бұрын

    Step by step good explanation. For writing test scenarios and feature, please suggest any documents.

  • @snehalmetkar
    @snehalmetkar4 ай бұрын

    Cucumber runner class wont work for 7.8.0 onwards dependencies, So for running the test cases with runner class use TestNG 7.7.1 dependency only

  • @SrihariNarra

    @SrihariNarra

    3 ай бұрын

    thanks for highlighting this.

  • @user-cj6vb8fs9v
    @user-cj6vb8fs9v4 ай бұрын

    Sir, why did we extend AbstractTestNGCucumberTests in runner class? Do we need to extend this to integrate testNG with cucumber? Normally we install testng from eclipse market place and add testng dependency rite?

  • @poojapawar5916
    @poojapawar59162 ай бұрын

    thank u sir

  • @sdetadda

    @sdetadda

    14 күн бұрын

    You are welcome!

  • @AsadSaeed-yn8nh
    @AsadSaeed-yn8nh3 ай бұрын

    I am making automation tests for a spring boot project using selenium cucumber. Do i have to put any new configurations?

  • @prabhakarmishra5099
    @prabhakarmishra50996 ай бұрын

    which java version you are using here? and please update me what is latest java version supported by cucumber??

  • @TranTran-oq1it
    @TranTran-oq1it5 ай бұрын

    Hello teacher, can I test using a website where I have the source code available? (and how to do it). Because using the url link often causes errors, I hope you will answer!

  • @rachaitabasu876
    @rachaitabasu87610 ай бұрын

    I can use this framework for API testing as well?Please explain how it will be very helpful thanks.

  • @shaheenafirdous8877
    @shaheenafirdous88777 ай бұрын

    But we need to create feature file under src/test/Java not resource

  • @vayamupadhyay966
    @vayamupadhyay9663 ай бұрын

    How can we run the feature using xml runner file ?

  • @ArjunK90
    @ArjunK902 ай бұрын

    Jun 15, 2024 6:50:54 PM cucumber.api.cli.Main run WARNING: You are using deprecated Main class. Please use io.cucumber.core.cli.Main Displaying this error when running the feature file. Please help me sir

  • @ramandhiman428
    @ramandhiman4284 ай бұрын

    Is there any video for cucumber gradle project

  • @sdetadda

    @sdetadda

    3 ай бұрын

    Will upload it soon into this channel. Let me know your requirements so that I can capture all details possible related to your project.

  • @dhammakkapandav9330
    @dhammakkapandav93304 ай бұрын

    Hi sir driver error is getting after importing WebDriver and chromedriver

  • @sultanbashashaik6531
    @sultanbashashaik6531Ай бұрын

    where did u gave chromedriver path

  • @sdetadda

    @sdetadda

    Ай бұрын

    @@sultanbashashaik6531 Not required in latest selenium 4.

  • @shaheenafirdous8877
    @shaheenafirdous88777 ай бұрын

    I m getting error when I m running it through testrunner file testng not found

  • @sdetadda

    @sdetadda

    7 ай бұрын

    Share the console errors/trace please.

  • @ratishnair4523
    @ratishnair45239 ай бұрын

    Sir, need a help , i have installed cucumber plugin and testng plugin in eclipse, created a feature file but logo is not changing to cucumber . what should i do ?😥

  • @praveenalgudkar764

    @praveenalgudkar764

    9 ай бұрын

    Right click on the project file and choose the option configure at the bottom and choose convert into cucumber project.

  • @ratishnair4523

    @ratishnair4523

    9 ай бұрын

    @@praveenalgudkar764 Sir , i followed still logo not changing to cucumber

  • @ratishnair4523

    @ratishnair4523

    9 ай бұрын

    two plugins have installed, i dont know why

  • @sdetadda

    @sdetadda

    9 ай бұрын

    Can you confirm the type of project and also if you can share the screenshot to help you out onto this?

  • @shivalingeshpatil2729
    @shivalingeshpatil27292 ай бұрын

    @sdetadda do u have course on udemy?

  • @sdetadda

    @sdetadda

    14 күн бұрын

    Not yet, but I'll start teaching on Udemy soon!

  • @abhilash7193
    @abhilash71935 ай бұрын

    Anyone please help me that I am getting below error/Warning " WARNING: You are using deprecated Main class. Please use io.cucumber.core.cli.Main" because of this my feature file is also not running i tried a lot to resolve this ,did google also but nothing happend.

  • @ArjunK90

    @ArjunK90

    2 ай бұрын

    Even same error for me

Келесі