Skip to main content

How to Setup the TestNG first Project in eclipse

In this article we will explain you about how to write the Test Cases  by using TestNG frame. here we will learn how to setup the TestNG framework in the Eclipse.
Step 1: First you need to create a Java project
Open the eclipse > Click on File  > Click on New > Click on Project
Selenium Web Driver, Automation Testing, Open Browser Script

Then select Java Project and then click on next Button
Selenium Web Driver, Automation Testing, Open Browser Script
Then right the project name and click on Next button then click on Finish Button
Selenium Web Driver, Automation Testing, Open Browser Script
Step 2: Now You need to create the package
for create the Package, First click on the newly created Project
Then Right Click on src folder > Click on New > Click on Package
Selenium Web Driver, Automation Testing, Open Browser Script, Select Package

Then Type the package name and click on Finish Button
Selenium Web Driver, Automation Testing, Open Browser Script, Package Name
Step 3: Now We need to create Class
Right Click on newly created package > click on New -> click on Class
Selenium Web Driver, Automation Testing, Open Browser Script, Create Class

Step 4: Now right click over the project name and select "Build Path" and then click on"Configure Build path"
Automation Testing, Selenium Web driver, TestNG Setup Guide

Step 5: In new opening window select "Libraries"
Automation testing, selenium Web driver, Guide to setup TestNG


Step 6: Now click on "Add Library" and select the TestNG from the next window and click on Next Button


Automation testing, selenium Web driver, guide to setup TestNG
and then click on Finish Button. You will see the TestNG in Libraries
Automation Testing, Selenium Web driver, TestNG setup Guide

Now click on Ok button of that window.
Step 7: Now Right click on the newly created class and , Took the mouse over "TestNG" and click on "create TestNG class"
then following window will open
Automation Testing, Selenium Web driver, TestNG Setup
Put the valid class name and click on finish button
then following code is showing . Here you can write your code 




Comments

Popular posts from this blog

Why Jmeter is best option for Performance Testing?

There are multiple tools in market for performance testing of any software but Jmeter is the best solution among all of them due to some reason listed below 1) Jmeter is the open source application so users who use this application will not to pay anything. 2) You can use Jmeter for performance of any web application,  Databases and Web Services (REST and SOAP APIs). 3) Jmeter have the user friendly UI component so it is very easy to use. 4) Jmeter can be used to simulate to put maximum number of concurrent users on a server, network or object to test its strength or to analyze overall performance under different load types. 5) Jmeter also use for functional testing for static( JavaScript and HTML) and dynamic( JSP, Servlets and AJAX) resources. 6) Jmeter provides Verity of graphical representations for performance report so it is easy to understand.

How You Can Test Database?

Now we know the Database Testing which you can learn in my last article. In this article we will discuss about the steps that need to following to test any Database. Database Tester should have some basic knowledge regarding SQL Command like DDL (create/drop),  DML (Insert/Delete/Update) and DCL (Grant/Revoke).

Record and Play Back in JMeter

In this section we will discuss about how to record a Test script than how we can play back that script in the browser. First we develop a  a Test Script than put a load of suppose 100 users and than run the test script again with this load while Test executing than we are getting result in performance matrices that how the Test performing in different number of users.