Selenium Cucumber Java BDD Framework 1 - Setup | Step by Step | Raghav Pal
ฝัง
- เผยแพร่เมื่อ 4 ก.ค. 2024
- Free Tutorials - automationstepbystep.com/
Quiz - forms.gle/XZeHkARaRi4K18Wm6
Step 1, create a maven project: 0:00-3:12
Step 2, download maven dependencies: 3:13-6:53
Step 3, create file structure: 6:54-8:19
Step 4, 5, 6, create feature file: 8:20-17:20
Step 7: 17:21-19:19
Step 8, glue code: 19:20-27:38
Step 9, runner class: 27:39
Step 1 - Create a new maven project
Step 2 - Add maven dependencies
Cucumber Java | Cucumber JUnit | JUnit | Selenium Java
Step 3 - Create a folder Features under src/test/resources
Step 4 - Under features folder create a new feature file login.feature
Step 5 - Download cucumber plugin from Eclipse Marketplace
Step 6 - Create feature file and add contents
Feature
Scenario
Steps
Scenario Outline
Example
Tags
Comments
Step 7 - Try to run the feature file
Step 8 - Add Step Definitions / Glue Code under src/test/java package
Step 9 - Create a Runner class
import org.junit.runner.RunWith;
import io.cucumber.junit.Cucumber;
import io.cucumber.junit.CucumberOptions;
@RunWith(Cucumber.class)
@CucumberOptions(features="src/test/resources/Features",
glue={"StepDefinitions"})
public class TestRunner {
}
monochrome = true
plugin = { "pretty", "html:target/reports"}
plugin = { "pretty", "json:target/reports/cucumber.json"}
plugin = { "pretty", "junit:target/reports/cucumber.xml"}
tags="@smoketest"
Step 10 - Create Add Cucumber Options for generating reports
HTML | JSON | JUNIT/XML
Step 11 - Run and verify results
Never Stop Learning
Raghav Pal
GitHub Repositories
github.com/Raghav-Pal/Seleniu...
github.com/Raghav-Pal/Cucumbe...
Join this channel to get access to perks: th-cam.com/users/automationste...
Hit Like and. Subscribe button, if you like this video. It gives me great motivation.
You can support my mission for education by sharing this knowledge and helping as many people as you can
If my work has helped you, consider helping animalaidunlimited.org/ or any animal welfare group near you, in any way you can.
Free courses - automationstepbystep.com/onli...
Udemy Discounts - automationstepbystep.com/udem...
Stories - automationstepbystep.com/stor...
In case you face issues generating HTML REPORT at 35:32 then under target folder manually create a folder named HtmlReports and in the code add the following:
plugin= {"pretty", "html:target/HtmlReports/report.html"}
(names can be changed)
Hi Sir ...I am getting only report.html under HtmlReports folder but the other files like formatter.js,jquery.js etc is not displaying...Could you please help in resolving this..Thanks in advance sir
Hi sir,I created HtmlReports manually and HTML report got stored under this folder but I am not able to see report even I opened report in web browser and not able to see json report
Hello Sir, I am getting abstract method error when run through JUNIT how to resolve it??
I am also facing the same issue not able to view the reports
@@pulkitsinghal5721 Please share your code for the plugin line. Followed as per authors instruction with no issue
. This is called Spoon feeding. You are a Super Start. God Bless you Raghava
Thanks for watching
Hello Raghav, I would first like to thank you for all of your hard work and great tutorials, I've finished watched your beginners Selenium course. One point I'm happy to make is you're now choosing descriptive file names, everything on that course was "test1, test2, test3" etc., a great improvement. Keep up the great content!!
So happy to know this
I wish I had found this video earlier in my testing career, this is really well done!!
thanks for liking Johnny
All the little mistakes you make during the presentation are brilliant for learning as one will invariably come across these kind of mistakes oneself.
You are easily the best most clear teacher on youtube. Excellent
So nice of you Mr Fay
I started BDD tutorial with some other channel twice, yet I couldn't follow. You are such a gem in teaching. Thanks mate!
I am so humbled to see this message Senthil
I agree! :)
strongly agree
I agree..
Hello Raghav! Thank you so much for this video. It is very helpful to understanding. I learned BDD framework only from your video. Since long times I was getting lots of errors but your explanation is awesome. Thanks a lot again!
Great to hear this Juhi
From the bottom of heart, I say thanks to you sir, my project was stuck, struggled for more than 3 days, atlast saw your video and got it cleared sir, thank you so much, please continue your great works sir
Most welcome Srinivasan
Excellent tutorials. Very understandable even for absolute beginners. Thank you.
Most welcome
As usual well explained step by step. Thank you, Raghav for providing such a video. You are really "Awesome".
Thanks a ton Manish
This is an excellent tutorial and I am so glad I found. It will familiarize you with everything you need to know to get started and give you a good foundation for learning more. Thanks so much!
Glad it was helpful Laura
@@RaghavPal It was great. I really needed something to get myself started for work, and was having much luck.
All the best Laura
Perfect systematic approach and explanation. Thank you. Waiting for following parts
Glad you liked it Rufat, Next part coming soon
One word for you sir " Fantastic" . each and every minute of your video enhance knowledge . Thank you So much .
You are most welcome
I was following a similar tutorial from Edureka. Couldn't make heads or tails of what was happening there. Your video is very easy to understand sir.
You're very welcome Pranoy, can get all here - automationstepbystep.com/
you are not the only one 😂i love the fact that Mr Pal does live coding so you get to follow much better.Edureka looses me
Hi Raghav, The tutorial was extremely useful. I could easily follow and do it. This tutorial is strongly recommended for others and I will do it. Great work !!!
So glad to see this Shaji, do share in all your groups
Excellent explication Raghav, thanks so much!
Glad it was helpful Maria
Thank you, for taking the time
and sharing your knowledge
Glad it was helpful!
Fantastic Video Tutorial, anyone can learn BDD Framework after watching this single video.
Glad to hear that Prasanna
Mr. Raghav. It is really really and really fantastic. I just follow your each second of deployment, and now i learnt a lot and end i am able to create the xml, hmtl and json based reports. Wow...more clarity...step by step...slow moves..... Your this video gives me more confident also. Surely will visit your series. Keep educate us/me. Thanks. Jeyakumar from Houston, Texas.
Glad to hear that Jeyakumar, Can find more here automationstepbystep.com/
This is what exactly am looking for! Thanks alot Raghav, it really helped me!
most welcome Jarvis
Hello Raghav...it's very very useful to me..I searched lot of videos with respect to this concept but here is I'm impressed a lot..keep u posting more videos :)
So nice of you Raghu
Thanks Raghav! This is very helpful in a easy understanding explanation! Can't wait for following sessions, please include bobcat framework, especially with bobcat aem6.5 module please!
Hi Adrienne, happy to know this. more coming up next week
Amazing .Explained it with so much ease which is perfect.
Thanks a lot Tulika
Thanks a lot, this is awesome. Session is very clear I am able to setup and run the tests successfully.
You are welcome!
Thanks for this detailed video :).. helps alot
Glad it was helpful Amit
Just one word to say "AWESOME"
Thanks
This is the best video i could find, being a selenium beginner , this is the best video for understanding setup and basics
Glad it was helpful Nandini
Really like your tutorials, they are very straight to the point and practical, thanks a lot Raghav!
Most welcome Andriy
Your explanation are very clear, I wish I had teachers like you. Thanks from Brazil!
This is so humbling Jean. Thanks for watching. Can find all here - automationstepbystep.com/
Perfect explanation. Thank u Raghav.
I hope you will cover POM with BDD as well, in the coming sessions.
Yes, soon Saurabh
I loved the way you explained each and every step. Thank you.
You are so welcome Divya
Thank you Raghav, your explanation and the way of approaching all in a prefect sync.
So happy to read this
Hi Raghav, for adding all the imports in stepdefinitions in one go, we can use, ctrl+A and shift+ctrl+O
thanks for adding
Raghav you are an outstanding teacher, instructor! Learning is never boring or tiring with you! These lessons are great, the way you teach is wonderful! You are the person that can make the perfect more perfect! Thank you so much!
Most welcome Jack
@@RaghavPal Thank you so much, did almost all 12 series in 2 days without any pressure or difficulty but with interest and enthusiasm!
He simply the greatest Instructor. I pick him any day over the rest.
humbled by your message
Thanks for saving me a lot of time. Explained very well.
You're welcome!
Well explained Raghav. Thank you!
Most welcome Meghan
Brilliant video.. I even shared this with my coworker.So impressive man wow thank you.
Thanks for sharing!
Thank you Sir for the information provided. I am very new to Selenium Cucumber but am I am able to follow your steps. You provide clear explanations.
So nice of you Geneci
your are amazing Ragahv !!! no words for your dedication and simplicity.
Thanks a lot Pravin
Thank you so much Raghav Pal , you are the Automation Legend.
I am so humbled to see your message, a lot is left to learn for me
Your explanation is awesome, desperately waiting for next part thank you☺️
Will upload soon Monisha, thanks for watching
Hello Raghav. Excellent explanation.
Thank you so much
Most welcome
Tq soo much Raghav pal sir for detailed explanation
You're welcome Maheedhar
Awesome one, Thank you for your clear explanation.
You're welcome Fazli
Thank You So much for creating this Playlist very help full.......Thank you Raghav sir
You are most welcome Sahil
Incredible work sir. Thank you so much for this!
Glad you liked it!
Thank you very much for putting these videos together. My boss was talking about Cucumber and how to use it for testing since I am in Qa dept. I tried many tutorials and there were not enough information and I need steps since all this is new for me. Thanks for the step by step process. I am going to view and learn from the other videos you have.
Great to know this helped
U explained very nice. I follow all steps it run Successfully. Thank you so much.
You are most welcome Ishan
Thanks Raghav, Have been waiting for this.
Most welcome! Manohar
Same here!! Thanks Raghav!
Thank you for all you effort!!!!!
Most welcome Roshan
Thankyou sir, your explanation and the way of approaching and the acsent all in a prefect sync. Making your sessions more intresting and very eager to learn. Thanks a lot for your great work sir.
You're most welcome Vignesh
Thank you so much. Clear explanation and statrted my cucumber framework journey with your guidance
You are most welcome
Such a wonderful experience
following this video Step to step Perfectly worked each and every statement.
thank you very much for the suggestion with the comments
reporting was not working and I look down to the comments.... and saw your first comment and guess what...!
it really worked.
looking forward to your next sessions.
you won a new subscriber today :D
Thanks for the message Phani. All the Best
Thanks so much for the wonderful explanation...
You're very welcome Sandhya
Thanks man, this is really helpful! Good Job!
Most welcome Porfirio
Hi Raghav,Cucumber video is Excellent with clear steps and easy to follow.I was facing so many errors but unable to solve was searching in youtube .Your videos is the only one solved my issue.Great Work....
so happy to know this Bala
Very helpful for the beginners in cucumber. Thanks so much.
Most welcome Ritik
Thank you Ragav for this session, it is short and clear. Awaiting for the upcoming sessions on Jenkins integration with this suite.
Thanks for watching Naveen. I will add more
Great Video Raghav, easy to follow & understand, thnks !!
Most welcome Balaji
Awesome learning... luv from USA
Thanks a lot
Another brilliant video Raghav. Thank you!
Most welcome Vinny
Excellent video series,Thanks Raghav
My pleasure Santhosh
You're amazing simply amazing I never commented on TH-cam but this is way too much to just watch the video and leave thank you from Canada!
Most welcome Ismail. thanks for the kind words
Thanks man, you rock. Very clear explanation.
I appreciate that!
Thanks a lot! Very informative.
You are welcome
Thank you so much Mr Raghav!!!!!!! You saved my life
Most welcome
you are awsome raghav greate explaination thank you so much
You're most welcome Manish
Amazing video, thank you!!
Glad you liked it!
Clearly understand the concept sir
Glad to know Kumar
Excellent content , I am able to follow these steps and setup cucumber successfully . Thank you Raghav .
Most welcome Gayatri
Thanks for this amazing serie videos 😊 , you rock dude 👏👏👏
Glad you like them Oscar
great teaching ! Simply amazing keep it up please🙏
Thanks Shirin
go through many BDD with Cucumber example but this video is too much helpful and well explained & content good thank you..
You are most welcome Sadhana
Thank you very much , it was easy learn with simple and clear materials
most welcome Nabinn
You just saved me! Your tutorial is way better than the test automation university!
Thanks a lot Sanjna
Thank you very much sir, well explained
Most welcome Asha
Thank you very much Sir. Excellent vdo for BDD.
Most welcome Sheetal
Indeed you are AWESOME MAN.
So kind of you Gourav
you are an angel for freshers
Thanks a lot. humbled
Thanks for your excellent teaching which is very easy for us to learn.thanks a lot.May the Creator bless you for your hardwork
You are most welcome Priya
Great Explanation, I am touched
Glad to hear that Prajual!. Humbled
Very nice explanation. Thank you so much 😊
Most welcome Sapna
Very good explanation......easy to follow and understand . Thank you !
Glad it was helpful!
Hi Ragahav, Really appreciate the effort you are putting to explain.
Most welcome Tapas
wish ,i would have found this earlier , you are just awesome and really great.! Thank you for all this!!
Most welcome Aashish
You are the Saviour ! Keep it up!
Thanks Ritesh
Thank you so much start
ed learning cucumber bdd , great session
Most welcome Rupali
Thank you Raghav for this ...was waiting fr long
You're welcome Dheeraj
Thank you so much for this video. It helped me a lot.
Glad it helped Shirish
Clear and Clever explanation
Thanks Marry
Fantastic and amazing!
Thanks Bryan
Thankyou Raghav for such a needed tutorial. .....
You're welcome Dheeraj
It's very useful and clear session ..thank you sir...
Always welcome Diptimayee
thanku so much Raghav sir for teaching us.
Most welcome Kapil
@RaghavPal You have put so much effort and clearly covered each and every point. Million zillion thanks and appreciate yourr hardwork and effort. 🙏🙏🙏
God bless you!!!
So nice of you Kavitha
perfect , this is the best tutorial
Thanks Negin
Thank you Sir for Great explanation as always.
Most welcome Tarik
Great Video, thanks for the help.
Most welcome
Very helpful tutorial. Thank you!
Most welcome Patrick