SlideShare a Scribd company logo
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
What Will You Learn Today?
 Limitations of Selenium WebDriver
 No support for testing images
 Not efficient Managing test cases
 No support Report generation
 Sikuli for testing images on the web
 Annotating tests and managing test cases using TestNG
 Generating HTML reports using TestNG
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Sikuli & TestNG Are Used In Selenium
WebDriver Because Of Its Limitations
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Shortcomings Of Selenium WebDriver
Dependency on external tools for Test management
Images cannot be tested in Web applications
Does not have Reporting facility
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
I have to verify
the images that
are present in
the web page
But, Selenium
doesn’t support
image based
testing
NOTE: Sikuli and Selenium can be integrated to also automate desktop applications
Need To Do Image Based Testing
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
I have to verify
the images that
are present in
the web page
But, Selenium
doesn’t support
image based
testing
NOTE: Sikuli and Selenium can be integrated to also automate desktop applications
Simple. Integrate
Sikuli with
Selenium for
testing images
Sikuli For Image Testing
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Selenium + Sikuli
Selenium
Sikuli
Image Testing + Web Testing
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
How Does Sikuli Work?
• Uses image recognition techniques to test images visible on screen
• It then performs operations on those images
• Provides a GUI for scripting where screenshots/ images are sent as
parameters
“Automate anything you see on your screen ”
-
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Sikuli IDE
• find
• findAll
• wait
• waitVanish
• exists
Image Searching Commands
• click
• doubleClick
• hover
• dragDrop
• rightClick
Mouse Action Commands
Image to be
recognized
Action to be
performed
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
I have a very long
code. Managing
various Test cases
is wearisome!
Neither do I
get detailed
reports about
those tests!!
Other Limitations Of Selenium
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
I have a very long
code. Managing
various Test cases
is wearisome!
Neither do I
get detailed
reports about
those tests!!
Both the problems can
be solved!
Use TestNG in Selenium
for Test management &
Report generation
TestNG To The Rescue
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
What Is TestNG?
TestNG is an open source testing framework inspired by JUnit. It stands for Test Next Generation
TestNG is more flexible & powerful than JUnit because of below functionalities:
T e s t
S c r i p t s
T E S T R E P O R T S
Prioritization
Method
Dependency
Parallel
Testing
Assertions
Disabling
Test Cases
GroupingAnnotations
Report
Generation
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Advantages Of Using TestNG
• HTML reports can be generated
• Supports parallel testing
• Test cases can be grouped & prioritized easily
• Uses annotations for executing methods
• Supports parameterization
Note: Java is a pre-requisite for TestNG
1. Write the business logic of the test and insert TestNG annotations in the code
2. Add the information about your test (e.g. the class names, methods names,
groups names etc.) in a testng.xml file or build.xml file
3. Run TestNG
Steps for writing TestNG tests
Advantages of using TestNG
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Annotations In TestNG
Annotations in TestNG are used to control the next method to be executed in the program
TestNG programs will not have ‘main’ method. However, all methods will be annotated with ‘@’
Test methods – Primary methods to be executed
Will be executed before both test method
Will be executed after both test method
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
List Of Annotations In TestNG
TESTNG ANNOTAIONS DESCRIPTION
@BeforeSuite Annotated method will run before all the tests in the suite have run
@AfterSuite Annotated method will run after all the tests in the suite have run
@BeforeTest Annotated method will run before any test method belonging to the classes is run
@AfterTest Annotated method will run after all the test methods belonging to the classes have run
@BeforeGroup Annotated method will run before each group is run
@AfterGroup Annotated method will run after every group is run
@BeforeClass Annotated method will run once before the first test method in the current class is invoked
@AfterClass Annotated method will run once after all the test methods in the current class have run
@BeforeMethod Annotated method will run before any test method belonging to the classes is run
@AfterMethod Annotated method will run after all the test methods belonging to the classes have run
@Test Annotated method is a part of test
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Examples Of Annotations In TestNG
public class TestngAnnotation {
@Test
public void testCase1()
{
System.out.println("in test case 1");
}
@BeforeMethod
public void beforeMethod() {
System.out.println("in beforeMethod");
}
@AfterMethod
public void afterMethod()
{
System.out.println("in afterMethod");
}
@BeforeTest
public void beforeTest()
{
System.out.println("in beforeTest");
}
@AfterTest
public void afterTest()
{
System.out.println("in afterTest");
} }
Main method to be executed
Will be executed before every test method
Will be executed after every test method
Will be executed before test
Will be executed after test
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Prioritization In TestNG
Annotated methods can be prioritized in TestNG
Priority can be assigned as parameters while calling the test cases
If no priority is defined, then the test cases will be executed in alphabetical order
Note: In this case, secondTest() will run first and then firstTest() will run
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Method Dependency In TestNG
Will execute only if finalTest() method passes
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
In TestNG, we can use dependsOnMethods to implement dependency testing
If the dependent method fails, then all the subsequent methods will be skipped
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Always Running Tests In TestNG
In TestNG, we can also choose to run a particular test irrespective of the fail/ pass condition of depending method
We can control that by setting the alwaysRun attribute in @Test annotation; alwaysRun = true
This test will run irrespective of finalTest()
passing/ failing
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
D i s a b l i n g
Te s t C a s e s
M e t h o d
D e p e n d e n c y
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Disabling Test Cases
In TestNG, we can enable or disable test/ test cases as per needs
We can control that by setting the enable attribute in @Test annotation; enabled=true or enabled=false
This test will never be executed in the test case
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Grouping Tests Into Test Cases
In TestNG, we can categorize certain methods into groups
Methods with same group name can be executed in one group
We can control that by setting the group attribute in @Test annotation; groups={“xxx”}
Note: A Test Case can belong to multiple test groups
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Assertions In TestNG
Assertions can be used in TestNG to compare the actual result with the expected result
Check if both String 1 and String 2 are equal
Check if call to aMethodCall() returns true
Checks if driver.getTitle() returns vale as “Gmail”
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Parallel Testing Using TestNG
TestNG provides support for executing scripts in parallel, saving lot of time
Multiple browser testing can be achieved as same scripts can be executed in multiple browser at the same time
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Running A TestNG Group Of Tests Via testng.xml
We can execute methods belonging to a group in TestNG, by creating testng.xml files
Grouping is one of the annotations, used to execute multiple tests
Open Eclipse and create a new file with the name testng.xml. Add the following code to the said file
This xml file contains only one test inside a suite. This
contains the groups section defined by using the groups
tag as shown in the code. The run tag represents the
group that needs to be run. The include tag represents
the name of the group that needs to be executed.
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
HTML Reports In TestNG
We can obtain detailed HTML test reports using TestNG
All test reports are saved in the test-output folder in eclipse project directory
A n n o t a t i o n s P r i o r i t i z a t i o n
R e p o r t
G e n e ra t i o n
P a r a l l e l
Te s t i n g
A s s e r t i o n sG r o u p i n g
M e t h o d
D e p e n d e n c y
D i s a b l i n g
Te s t C a s e s
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Course Details & Customer Reviews
Go to www.edureka.co/testing-with-selenium-webdriver
Get Edureka Certified in Selenium Today!
Radha Muthian says, “I learned Selenium WebDriver and the course
was very helpful to automate the Web Applications. The lifetime
access of classes helps a lot to refer back and download the codes.”
Vijay Krishnan says, “I have attended Selenium Web driver Certification with
Edureka. The trainer has explained all the concepts of the course in detail
manner which was very easy to understand. Worth for the money spent!!!!”
Tom Tully says, “I wanted to learn Selenium Webdriver in a live, real
course, not self paced, so there would be pressure on me to finish.
Edureka accomplished this at a price far lower than an in-person class,
and as far as I know they are the only internet class that has live lectures
on this subject. Teacher was very knowledgeable. I learned basic use of
Selenium. No problem with me being in US and teacher in India. They
have US 800 number.”
Suhas Kashyap says, “The online Course(Selenium Webdriver), which
I took from Edureka was interactive and also helped me to improve
my knowledge on selenium. Further helped me in changing the job as
well. Thanks Edureka Team... :).”
www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING
Ad

More Related Content

What's hot (20)

Test Automation Framework Designs
Test Automation Framework DesignsTest Automation Framework Designs
Test Automation Framework Designs
Sauce Labs
 
Selenium Primer
Selenium PrimerSelenium Primer
Selenium Primer
gueste1e4db
 
Selenium
SeleniumSelenium
Selenium
Adam Goucher
 
Selenium TestNG
Selenium TestNGSelenium TestNG
Selenium TestNG
KadarkaraiSelvam
 
Selenium Handbook
Selenium HandbookSelenium Handbook
Selenium Handbook
Suresh Thammishetty
 
Selenium
SeleniumSelenium
Selenium
mdfkhan625
 
Introduction to Selenium Web Driver
Introduction to Selenium Web DriverIntroduction to Selenium Web Driver
Introduction to Selenium Web Driver
Return on Intelligence
 
Selenium
SeleniumSelenium
Selenium
Kalyan ch
 
Selenium with java
Selenium with javaSelenium with java
Selenium with java
Gousalya Ramachandran
 
Web automation using selenium.ppt
Web automation using selenium.pptWeb automation using selenium.ppt
Web automation using selenium.ppt
Ana Sarbescu
 
Selenium Presentation at Engineering Colleges
Selenium Presentation at Engineering CollegesSelenium Presentation at Engineering Colleges
Selenium Presentation at Engineering Colleges
Vijay Rangaiah
 
Selenium IDE LOCATORS
Selenium IDE LOCATORSSelenium IDE LOCATORS
Selenium IDE LOCATORS
Mindfire Solutions
 
Introduction to Selenium Automation
Introduction to Selenium AutomationIntroduction to Selenium Automation
Introduction to Selenium Automation
Mindfire Solutions
 
Selenium introduction
Selenium introductionSelenium introduction
Selenium introduction
Pankaj Dubey
 
Hybrid framework
Hybrid frameworkHybrid framework
Hybrid framework
Sudhakar Mangi
 
An overview of selenium webdriver
An overview of selenium webdriverAn overview of selenium webdriver
An overview of selenium webdriver
Anuraj S.L
 
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
Edureka!
 
Python selenium
Python seleniumPython selenium
Python selenium
Ducat
 
Test Automation and Selenium
Test Automation and SeleniumTest Automation and Selenium
Test Automation and Selenium
Karapet Sarkisyan
 
Selenium WebDriver
Selenium WebDriverSelenium WebDriver
Selenium WebDriver
Yuriy Bezgachnyuk
 
Test Automation Framework Designs
Test Automation Framework DesignsTest Automation Framework Designs
Test Automation Framework Designs
Sauce Labs
 
Web automation using selenium.ppt
Web automation using selenium.pptWeb automation using selenium.ppt
Web automation using selenium.ppt
Ana Sarbescu
 
Selenium Presentation at Engineering Colleges
Selenium Presentation at Engineering CollegesSelenium Presentation at Engineering Colleges
Selenium Presentation at Engineering Colleges
Vijay Rangaiah
 
Introduction to Selenium Automation
Introduction to Selenium AutomationIntroduction to Selenium Automation
Introduction to Selenium Automation
Mindfire Solutions
 
Selenium introduction
Selenium introductionSelenium introduction
Selenium introduction
Pankaj Dubey
 
An overview of selenium webdriver
An overview of selenium webdriverAn overview of selenium webdriver
An overview of selenium webdriver
Anuraj S.L
 
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
How to Write & Run a Test Case in Selenium | Selenium Tutorial | Selenium Tra...
Edureka!
 
Python selenium
Python seleniumPython selenium
Python selenium
Ducat
 
Test Automation and Selenium
Test Automation and SeleniumTest Automation and Selenium
Test Automation and Selenium
Karapet Sarkisyan
 

Similar to Selenium Training | TestNG Framework For Selenium | Selenium Tutorial For Beginners | Edureka (20)

Dev labs alliance top 20 testng interview questions for sdet
Dev labs alliance top 20 testng interview questions for sdetDev labs alliance top 20 testng interview questions for sdet
Dev labs alliance top 20 testng interview questions for sdet
devlabsalliance
 
Test ng for testers
Test ng for testersTest ng for testers
Test ng for testers
Colombo Selenium Meetup
 
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, MinskApplicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Dmitriy Gumeniuk
 
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Edureka!
 
Testing concept definition
Testing concept definitionTesting concept definition
Testing concept definition
Vivek V
 
TestNG Annotations in Selenium | Edureka
TestNG Annotations in Selenium | EdurekaTestNG Annotations in Selenium | Edureka
TestNG Annotations in Selenium | Edureka
Edureka!
 
Manage Testing by Dependencies—Not Activities
Manage Testing by Dependencies—Not ActivitiesManage Testing by Dependencies—Not Activities
Manage Testing by Dependencies—Not Activities
TechWell
 
The Components Of Testing 0309 V2
The Components Of Testing 0309  V2The Components Of Testing 0309  V2
The Components Of Testing 0309 V2
Devukjs
 
Selenium Training and Certification.pdf
Selenium Training and Certification.pdfSelenium Training and Certification.pdf
Selenium Training and Certification.pdf
alicesmith2209
 
Myths about Exploratory Testing - Agile Testing Days
Myths about Exploratory Testing - Agile Testing DaysMyths about Exploratory Testing - Agile Testing Days
Myths about Exploratory Testing - Agile Testing Days
Ravneet Kaur
 
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and MavenWebtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Thorsten Kamann
 
Application Testing
Application TestingApplication Testing
Application Testing
Reggie Niccolo Santos
 
SoapUI: Day5: web service test steps in soapui
SoapUI: Day5:  web service test steps in soapuiSoapUI: Day5:  web service test steps in soapui
SoapUI: Day5: web service test steps in soapui
Testing World
 
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Edureka!
 
Test NG Framework Complete Walk Through
Test NG Framework Complete Walk ThroughTest NG Framework Complete Walk Through
Test NG Framework Complete Walk Through
Narendran Solai Sridharan
 
2007 Microsoft Excel Test Score
2007 Microsoft Excel Test Score2007 Microsoft Excel Test Score
2007 Microsoft Excel Test Score
chamblisss
 
Test Cases in Software Testing Examples PDF By QA Company in USA
Test Cases in Software Testing Examples PDF By QA Company in USATest Cases in Software Testing Examples PDF By QA Company in USA
Test Cases in Software Testing Examples PDF By QA Company in USA
Testrig Technologies
 
Testing in java
Testing in javaTesting in java
Testing in java
Levent YILDIZ
 
19 creamer et workshop-agile2019-wash_pp_16-9_1
19 creamer et workshop-agile2019-wash_pp_16-9_119 creamer et workshop-agile2019-wash_pp_16-9_1
19 creamer et workshop-agile2019-wash_pp_16-9_1
Lanette Creamer
 
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
QA or the Highway
 
Dev labs alliance top 20 testng interview questions for sdet
Dev labs alliance top 20 testng interview questions for sdetDev labs alliance top 20 testng interview questions for sdet
Dev labs alliance top 20 testng interview questions for sdet
devlabsalliance
 
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, MinskApplicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Applicabilitity of Machine Learning in Test Automation @ Delex Conf 2018, Minsk
Dmitriy Gumeniuk
 
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Software Testing Tutorial For Beginners | Manual & Automation Testing | Selen...
Edureka!
 
Testing concept definition
Testing concept definitionTesting concept definition
Testing concept definition
Vivek V
 
TestNG Annotations in Selenium | Edureka
TestNG Annotations in Selenium | EdurekaTestNG Annotations in Selenium | Edureka
TestNG Annotations in Selenium | Edureka
Edureka!
 
Manage Testing by Dependencies—Not Activities
Manage Testing by Dependencies—Not ActivitiesManage Testing by Dependencies—Not Activities
Manage Testing by Dependencies—Not Activities
TechWell
 
The Components Of Testing 0309 V2
The Components Of Testing 0309  V2The Components Of Testing 0309  V2
The Components Of Testing 0309 V2
Devukjs
 
Selenium Training and Certification.pdf
Selenium Training and Certification.pdfSelenium Training and Certification.pdf
Selenium Training and Certification.pdf
alicesmith2209
 
Myths about Exploratory Testing - Agile Testing Days
Myths about Exploratory Testing - Agile Testing DaysMyths about Exploratory Testing - Agile Testing Days
Myths about Exploratory Testing - Agile Testing Days
Ravneet Kaur
 
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and MavenWebtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Webtests Reloaded - Webtest with Selenium, TestNG, Groovy and Maven
Thorsten Kamann
 
SoapUI: Day5: web service test steps in soapui
SoapUI: Day5:  web service test steps in soapuiSoapUI: Day5:  web service test steps in soapui
SoapUI: Day5: web service test steps in soapui
Testing World
 
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Selenium IDE Tutorial For Beginners | What Is Selenium IDE? | Selenium Tutori...
Edureka!
 
2007 Microsoft Excel Test Score
2007 Microsoft Excel Test Score2007 Microsoft Excel Test Score
2007 Microsoft Excel Test Score
chamblisss
 
Test Cases in Software Testing Examples PDF By QA Company in USA
Test Cases in Software Testing Examples PDF By QA Company in USATest Cases in Software Testing Examples PDF By QA Company in USA
Test Cases in Software Testing Examples PDF By QA Company in USA
Testrig Technologies
 
19 creamer et workshop-agile2019-wash_pp_16-9_1
19 creamer et workshop-agile2019-wash_pp_16-9_119 creamer et workshop-agile2019-wash_pp_16-9_1
19 creamer et workshop-agile2019-wash_pp_16-9_1
Lanette Creamer
 
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
Quality Leadership, Testing, and Governance Tactics that Make or Break Your P...
QA or the Highway
 
Ad

More from Edureka! (20)

What to learn during the 21 days Lockdown | Edureka
What to learn during the 21 days Lockdown | EdurekaWhat to learn during the 21 days Lockdown | Edureka
What to learn during the 21 days Lockdown | Edureka
Edureka!
 
Top 10 Dying Programming Languages in 2020 | Edureka
Top 10 Dying Programming Languages in 2020 | EdurekaTop 10 Dying Programming Languages in 2020 | Edureka
Top 10 Dying Programming Languages in 2020 | Edureka
Edureka!
 
Top 5 Trending Business Intelligence Tools | Edureka
Top 5 Trending Business Intelligence Tools | EdurekaTop 5 Trending Business Intelligence Tools | Edureka
Top 5 Trending Business Intelligence Tools | Edureka
Edureka!
 
Tableau Tutorial for Data Science | Edureka
Tableau Tutorial for Data Science | EdurekaTableau Tutorial for Data Science | Edureka
Tableau Tutorial for Data Science | Edureka
Edureka!
 
Python Programming Tutorial | Edureka
Python Programming Tutorial | EdurekaPython Programming Tutorial | Edureka
Python Programming Tutorial | Edureka
Edureka!
 
Top 5 PMP Certifications | Edureka
Top 5 PMP Certifications | EdurekaTop 5 PMP Certifications | Edureka
Top 5 PMP Certifications | Edureka
Edureka!
 
Top Maven Interview Questions in 2020 | Edureka
Top Maven Interview Questions in 2020 | EdurekaTop Maven Interview Questions in 2020 | Edureka
Top Maven Interview Questions in 2020 | Edureka
Edureka!
 
Linux Mint Tutorial | Edureka
Linux Mint Tutorial | EdurekaLinux Mint Tutorial | Edureka
Linux Mint Tutorial | Edureka
Edureka!
 
How to Deploy Java Web App in AWS| Edureka
How to Deploy Java Web App in AWS| EdurekaHow to Deploy Java Web App in AWS| Edureka
How to Deploy Java Web App in AWS| Edureka
Edureka!
 
Importance of Digital Marketing | Edureka
Importance of Digital Marketing | EdurekaImportance of Digital Marketing | Edureka
Importance of Digital Marketing | Edureka
Edureka!
 
RPA in 2020 | Edureka
RPA in 2020 | EdurekaRPA in 2020 | Edureka
RPA in 2020 | Edureka
Edureka!
 
Email Notifications in Jenkins | Edureka
Email Notifications in Jenkins | EdurekaEmail Notifications in Jenkins | Edureka
Email Notifications in Jenkins | Edureka
Edureka!
 
EA Algorithm in Machine Learning | Edureka
EA Algorithm in Machine Learning | EdurekaEA Algorithm in Machine Learning | Edureka
EA Algorithm in Machine Learning | Edureka
Edureka!
 
Cognitive AI Tutorial | Edureka
Cognitive AI Tutorial | EdurekaCognitive AI Tutorial | Edureka
Cognitive AI Tutorial | Edureka
Edureka!
 
AWS Cloud Practitioner Tutorial | Edureka
AWS Cloud Practitioner Tutorial | EdurekaAWS Cloud Practitioner Tutorial | Edureka
AWS Cloud Practitioner Tutorial | Edureka
Edureka!
 
Blue Prism Top Interview Questions | Edureka
Blue Prism Top Interview Questions | EdurekaBlue Prism Top Interview Questions | Edureka
Blue Prism Top Interview Questions | Edureka
Edureka!
 
Big Data on AWS Tutorial | Edureka
Big Data on AWS Tutorial | Edureka Big Data on AWS Tutorial | Edureka
Big Data on AWS Tutorial | Edureka
Edureka!
 
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
A star algorithm | A* Algorithm in Artificial Intelligence | EdurekaA star algorithm | A* Algorithm in Artificial Intelligence | Edureka
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
Edureka!
 
Kubernetes Installation on Ubuntu | Edureka
Kubernetes Installation on Ubuntu | EdurekaKubernetes Installation on Ubuntu | Edureka
Kubernetes Installation on Ubuntu | Edureka
Edureka!
 
Introduction to DevOps | Edureka
Introduction to DevOps | EdurekaIntroduction to DevOps | Edureka
Introduction to DevOps | Edureka
Edureka!
 
What to learn during the 21 days Lockdown | Edureka
What to learn during the 21 days Lockdown | EdurekaWhat to learn during the 21 days Lockdown | Edureka
What to learn during the 21 days Lockdown | Edureka
Edureka!
 
Top 10 Dying Programming Languages in 2020 | Edureka
Top 10 Dying Programming Languages in 2020 | EdurekaTop 10 Dying Programming Languages in 2020 | Edureka
Top 10 Dying Programming Languages in 2020 | Edureka
Edureka!
 
Top 5 Trending Business Intelligence Tools | Edureka
Top 5 Trending Business Intelligence Tools | EdurekaTop 5 Trending Business Intelligence Tools | Edureka
Top 5 Trending Business Intelligence Tools | Edureka
Edureka!
 
Tableau Tutorial for Data Science | Edureka
Tableau Tutorial for Data Science | EdurekaTableau Tutorial for Data Science | Edureka
Tableau Tutorial for Data Science | Edureka
Edureka!
 
Python Programming Tutorial | Edureka
Python Programming Tutorial | EdurekaPython Programming Tutorial | Edureka
Python Programming Tutorial | Edureka
Edureka!
 
Top 5 PMP Certifications | Edureka
Top 5 PMP Certifications | EdurekaTop 5 PMP Certifications | Edureka
Top 5 PMP Certifications | Edureka
Edureka!
 
Top Maven Interview Questions in 2020 | Edureka
Top Maven Interview Questions in 2020 | EdurekaTop Maven Interview Questions in 2020 | Edureka
Top Maven Interview Questions in 2020 | Edureka
Edureka!
 
Linux Mint Tutorial | Edureka
Linux Mint Tutorial | EdurekaLinux Mint Tutorial | Edureka
Linux Mint Tutorial | Edureka
Edureka!
 
How to Deploy Java Web App in AWS| Edureka
How to Deploy Java Web App in AWS| EdurekaHow to Deploy Java Web App in AWS| Edureka
How to Deploy Java Web App in AWS| Edureka
Edureka!
 
Importance of Digital Marketing | Edureka
Importance of Digital Marketing | EdurekaImportance of Digital Marketing | Edureka
Importance of Digital Marketing | Edureka
Edureka!
 
RPA in 2020 | Edureka
RPA in 2020 | EdurekaRPA in 2020 | Edureka
RPA in 2020 | Edureka
Edureka!
 
Email Notifications in Jenkins | Edureka
Email Notifications in Jenkins | EdurekaEmail Notifications in Jenkins | Edureka
Email Notifications in Jenkins | Edureka
Edureka!
 
EA Algorithm in Machine Learning | Edureka
EA Algorithm in Machine Learning | EdurekaEA Algorithm in Machine Learning | Edureka
EA Algorithm in Machine Learning | Edureka
Edureka!
 
Cognitive AI Tutorial | Edureka
Cognitive AI Tutorial | EdurekaCognitive AI Tutorial | Edureka
Cognitive AI Tutorial | Edureka
Edureka!
 
AWS Cloud Practitioner Tutorial | Edureka
AWS Cloud Practitioner Tutorial | EdurekaAWS Cloud Practitioner Tutorial | Edureka
AWS Cloud Practitioner Tutorial | Edureka
Edureka!
 
Blue Prism Top Interview Questions | Edureka
Blue Prism Top Interview Questions | EdurekaBlue Prism Top Interview Questions | Edureka
Blue Prism Top Interview Questions | Edureka
Edureka!
 
Big Data on AWS Tutorial | Edureka
Big Data on AWS Tutorial | Edureka Big Data on AWS Tutorial | Edureka
Big Data on AWS Tutorial | Edureka
Edureka!
 
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
A star algorithm | A* Algorithm in Artificial Intelligence | EdurekaA star algorithm | A* Algorithm in Artificial Intelligence | Edureka
A star algorithm | A* Algorithm in Artificial Intelligence | Edureka
Edureka!
 
Kubernetes Installation on Ubuntu | Edureka
Kubernetes Installation on Ubuntu | EdurekaKubernetes Installation on Ubuntu | Edureka
Kubernetes Installation on Ubuntu | Edureka
Edureka!
 
Introduction to DevOps | Edureka
Introduction to DevOps | EdurekaIntroduction to DevOps | Edureka
Introduction to DevOps | Edureka
Edureka!
 
Ad

Recently uploaded (20)

How to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud PerformanceHow to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud Performance
ThousandEyes
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Download YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full ActivatedDownload YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full Activated
saniamalik72555
 
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software DevelopmentSecure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Shubham Joshi
 
WinRAR Crack for Windows (100% Working 2025)
WinRAR Crack for Windows (100% Working 2025)WinRAR Crack for Windows (100% Working 2025)
WinRAR Crack for Windows (100% Working 2025)
sh607827
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRYLEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
NidaFarooq10
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& ConsiderationsDesigning AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Dinusha Kumarasiri
 
Kubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptxKubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptx
CloudScouts
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
How can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptxHow can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptx
laravinson24
 
Societal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainabilitySocietal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainability
Jordi Cabot
 
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage DashboardsAdobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
BradBedford3
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
The Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdfThe Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdf
drewplanas10
 
Adobe Lightroom Classic Crack FREE Latest link 2025
Adobe Lightroom Classic Crack FREE Latest link 2025Adobe Lightroom Classic Crack FREE Latest link 2025
Adobe Lightroom Classic Crack FREE Latest link 2025
kashifyounis067
 
How to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud PerformanceHow to Optimize Your AWS Environment for Improved Cloud Performance
How to Optimize Your AWS Environment for Improved Cloud Performance
ThousandEyes
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Download YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full ActivatedDownload YouTube By Click 2025 Free Full Activated
Download YouTube By Click 2025 Free Full Activated
saniamalik72555
 
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software DevelopmentSecure Test Infrastructure: The Backbone of Trustworthy Software Development
Secure Test Infrastructure: The Backbone of Trustworthy Software Development
Shubham Joshi
 
WinRAR Crack for Windows (100% Working 2025)
WinRAR Crack for Windows (100% Working 2025)WinRAR Crack for Windows (100% Working 2025)
WinRAR Crack for Windows (100% Working 2025)
sh607827
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRYLEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
LEARN SEO AND INCREASE YOUR KNOWLDGE IN SOFTWARE INDUSTRY
NidaFarooq10
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& ConsiderationsDesigning AI-Powered APIs on Azure: Best Practices& Considerations
Designing AI-Powered APIs on Azure: Best Practices& Considerations
Dinusha Kumarasiri
 
Kubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptxKubernetes_101_Zero_to_Platform_Engineer.pptx
Kubernetes_101_Zero_to_Platform_Engineer.pptx
CloudScouts
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
How can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptxHow can one start with crypto wallet development.pptx
How can one start with crypto wallet development.pptx
laravinson24
 
Societal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainabilitySocietal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainability
Jordi Cabot
 
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage DashboardsAdobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
BradBedford3
 
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...Explaining GitHub Actions Failures with Large Language Models Challenges, In...
Explaining GitHub Actions Failures with Large Language Models Challenges, In...
ssuserb14185
 
The Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdfThe Significance of Hardware in Information Systems.pdf
The Significance of Hardware in Information Systems.pdf
drewplanas10
 
Adobe Lightroom Classic Crack FREE Latest link 2025
Adobe Lightroom Classic Crack FREE Latest link 2025Adobe Lightroom Classic Crack FREE Latest link 2025
Adobe Lightroom Classic Crack FREE Latest link 2025
kashifyounis067
 

Selenium Training | TestNG Framework For Selenium | Selenium Tutorial For Beginners | Edureka

  • 2. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING What Will You Learn Today?  Limitations of Selenium WebDriver  No support for testing images  Not efficient Managing test cases  No support Report generation  Sikuli for testing images on the web  Annotating tests and managing test cases using TestNG  Generating HTML reports using TestNG
  • 3. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Sikuli & TestNG Are Used In Selenium WebDriver Because Of Its Limitations
  • 4. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Shortcomings Of Selenium WebDriver Dependency on external tools for Test management Images cannot be tested in Web applications Does not have Reporting facility
  • 5. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING I have to verify the images that are present in the web page But, Selenium doesn’t support image based testing NOTE: Sikuli and Selenium can be integrated to also automate desktop applications Need To Do Image Based Testing
  • 6. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING I have to verify the images that are present in the web page But, Selenium doesn’t support image based testing NOTE: Sikuli and Selenium can be integrated to also automate desktop applications Simple. Integrate Sikuli with Selenium for testing images Sikuli For Image Testing
  • 7. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Selenium + Sikuli Selenium Sikuli Image Testing + Web Testing
  • 8. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING How Does Sikuli Work? • Uses image recognition techniques to test images visible on screen • It then performs operations on those images • Provides a GUI for scripting where screenshots/ images are sent as parameters “Automate anything you see on your screen ” -
  • 9. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Sikuli IDE • find • findAll • wait • waitVanish • exists Image Searching Commands • click • doubleClick • hover • dragDrop • rightClick Mouse Action Commands Image to be recognized Action to be performed
  • 10. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING I have a very long code. Managing various Test cases is wearisome! Neither do I get detailed reports about those tests!! Other Limitations Of Selenium
  • 11. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING I have a very long code. Managing various Test cases is wearisome! Neither do I get detailed reports about those tests!! Both the problems can be solved! Use TestNG in Selenium for Test management & Report generation TestNG To The Rescue
  • 12. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING What Is TestNG? TestNG is an open source testing framework inspired by JUnit. It stands for Test Next Generation TestNG is more flexible & powerful than JUnit because of below functionalities: T e s t S c r i p t s T E S T R E P O R T S Prioritization Method Dependency Parallel Testing Assertions Disabling Test Cases GroupingAnnotations Report Generation
  • 13. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Advantages Of Using TestNG • HTML reports can be generated • Supports parallel testing • Test cases can be grouped & prioritized easily • Uses annotations for executing methods • Supports parameterization Note: Java is a pre-requisite for TestNG 1. Write the business logic of the test and insert TestNG annotations in the code 2. Add the information about your test (e.g. the class names, methods names, groups names etc.) in a testng.xml file or build.xml file 3. Run TestNG Steps for writing TestNG tests Advantages of using TestNG
  • 14. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Annotations In TestNG Annotations in TestNG are used to control the next method to be executed in the program TestNG programs will not have ‘main’ method. However, all methods will be annotated with ‘@’ Test methods – Primary methods to be executed Will be executed before both test method Will be executed after both test method A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 15. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING List Of Annotations In TestNG TESTNG ANNOTAIONS DESCRIPTION @BeforeSuite Annotated method will run before all the tests in the suite have run @AfterSuite Annotated method will run after all the tests in the suite have run @BeforeTest Annotated method will run before any test method belonging to the classes is run @AfterTest Annotated method will run after all the test methods belonging to the classes have run @BeforeGroup Annotated method will run before each group is run @AfterGroup Annotated method will run after every group is run @BeforeClass Annotated method will run once before the first test method in the current class is invoked @AfterClass Annotated method will run once after all the test methods in the current class have run @BeforeMethod Annotated method will run before any test method belonging to the classes is run @AfterMethod Annotated method will run after all the test methods belonging to the classes have run @Test Annotated method is a part of test A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 16. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Examples Of Annotations In TestNG public class TestngAnnotation { @Test public void testCase1() { System.out.println("in test case 1"); } @BeforeMethod public void beforeMethod() { System.out.println("in beforeMethod"); } @AfterMethod public void afterMethod() { System.out.println("in afterMethod"); } @BeforeTest public void beforeTest() { System.out.println("in beforeTest"); } @AfterTest public void afterTest() { System.out.println("in afterTest"); } } Main method to be executed Will be executed before every test method Will be executed after every test method Will be executed before test Will be executed after test
  • 17. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Prioritization In TestNG Annotated methods can be prioritized in TestNG Priority can be assigned as parameters while calling the test cases If no priority is defined, then the test cases will be executed in alphabetical order Note: In this case, secondTest() will run first and then firstTest() will run A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 18. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Method Dependency In TestNG Will execute only if finalTest() method passes A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s In TestNG, we can use dependsOnMethods to implement dependency testing If the dependent method fails, then all the subsequent methods will be skipped
  • 19. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Always Running Tests In TestNG In TestNG, we can also choose to run a particular test irrespective of the fail/ pass condition of depending method We can control that by setting the alwaysRun attribute in @Test annotation; alwaysRun = true This test will run irrespective of finalTest() passing/ failing A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g D i s a b l i n g Te s t C a s e s M e t h o d D e p e n d e n c y
  • 20. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Disabling Test Cases In TestNG, we can enable or disable test/ test cases as per needs We can control that by setting the enable attribute in @Test annotation; enabled=true or enabled=false This test will never be executed in the test case A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 21. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Grouping Tests Into Test Cases In TestNG, we can categorize certain methods into groups Methods with same group name can be executed in one group We can control that by setting the group attribute in @Test annotation; groups={“xxx”} Note: A Test Case can belong to multiple test groups A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 22. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Assertions In TestNG Assertions can be used in TestNG to compare the actual result with the expected result Check if both String 1 and String 2 are equal Check if call to aMethodCall() returns true Checks if driver.getTitle() returns vale as “Gmail” A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 23. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Parallel Testing Using TestNG TestNG provides support for executing scripts in parallel, saving lot of time Multiple browser testing can be achieved as same scripts can be executed in multiple browser at the same time A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 24. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Running A TestNG Group Of Tests Via testng.xml We can execute methods belonging to a group in TestNG, by creating testng.xml files Grouping is one of the annotations, used to execute multiple tests Open Eclipse and create a new file with the name testng.xml. Add the following code to the said file This xml file contains only one test inside a suite. This contains the groups section defined by using the groups tag as shown in the code. The run tag represents the group that needs to be run. The include tag represents the name of the group that needs to be executed. A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 25. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING HTML Reports In TestNG We can obtain detailed HTML test reports using TestNG All test reports are saved in the test-output folder in eclipse project directory A n n o t a t i o n s P r i o r i t i z a t i o n R e p o r t G e n e ra t i o n P a r a l l e l Te s t i n g A s s e r t i o n sG r o u p i n g M e t h o d D e p e n d e n c y D i s a b l i n g Te s t C a s e s
  • 26. www.edureka.co/testing-with-selenium-webdriverEDUREKA’S SELENIUM CERTIFICATION TRAINING Course Details & Customer Reviews Go to www.edureka.co/testing-with-selenium-webdriver Get Edureka Certified in Selenium Today! Radha Muthian says, “I learned Selenium WebDriver and the course was very helpful to automate the Web Applications. The lifetime access of classes helps a lot to refer back and download the codes.” Vijay Krishnan says, “I have attended Selenium Web driver Certification with Edureka. The trainer has explained all the concepts of the course in detail manner which was very easy to understand. Worth for the money spent!!!!” Tom Tully says, “I wanted to learn Selenium Webdriver in a live, real course, not self paced, so there would be pressure on me to finish. Edureka accomplished this at a price far lower than an in-person class, and as far as I know they are the only internet class that has live lectures on this subject. Teacher was very knowledgeable. I learned basic use of Selenium. No problem with me being in US and teacher in India. They have US 800 number.” Suhas Kashyap says, “The online Course(Selenium Webdriver), which I took from Edureka was interactive and also helped me to improve my knowledge on selenium. Further helped me in changing the job as well. Thanks Edureka Team... :).”

Editor's Notes

  • #13: InvocationCount Attributes
  • #27: Add photos