123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Computers >> View Article

Testng Tutorial-understanding The Testng Framework

Profile Picture
By Author: S S Pathak
Total Articles: 1
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

Originally inspired by JUnit and NUnit, testNG is a testing framework developed by Java. To understand the concept behind the framework, you could start by undertaking a testng tutorial. The framework has adopted some new innovative technology that makes its easy to use and it is also very reliable.

Originally inspired by JUnit and NUnit, testNG is a testing framework developed by Java. To understand the concept behind the framework, you could start by undertaking a testng tutorial. The framework has adopted some new innovative technology that makes its easy to use and it is also very reliable. TestNG is designed in such a manner that it covers all categories of tests. Some of the test categories covered include unit, end-to-end and functional. The main aim of testNG is to enhance efficiency. The letters NG stands for ‘next generation’. It is an improvement of the originally used test frameworks. Upon undertaking the testng tutorial, you will have an understanding of broader and deeper test coverage.

The use of testNG has been adopted by many individuals due to the many advantages of the framework. The ...
... framework overcomes the limitations of other popular testing frameworks such as JUnit. Some of the main advantages of testNG over JUnit include; annotations that are easier to understand. The testng annotations are much easier to understand than those of JUnit. It is very easy to group tests accordingly. With testNG, parallel testing is usually possible. What are testng annotations? They are lines of codes that usually control how the method below them will be executed. The annotations are always preceded by @ symbol.

Mainly testNG frameworks are based on testng eclipse. Whenever you are installing testng in eclipse, there are various steps that you need to follow. To begin with, launch eclipse. Then proceed to the Help menu where you choose the ‘Install software’ option. The next option involves choosing the ‘add’ button on the install dialog box. When you complete installing the testNG, eclipse may restart. Upon restarting, you will simply verify that testNG was successfully installed. If you are currently using JUnit testing, you can convert it into testNG. The easiest way to do this is by using the testing eclipse plug-in refactoring support.

Under the testng tutorial, you will understand how to write tests in testNG. There are three main steps that need to be followed. In the first step, write the business logic of the test. Also ensure that you insert the testng annotations at this step. Some examples of annotations that are used in testing include the following; @beforehand, @afterclass, @beforeclass, @before suite and@ dataprovider to name just but a few. On configuring testNG using some annotations, you will be able to perform some java logic before and after certain points. In testNG, tests are run in the order in which they are found in testng.xls file.

Also covered under testng eclipse tutorials are the various dependencies in testNG. Normally, dependencies are usually specified with annotations or in xml file. The two main types of dependencies are; Hard dependency and soft dependency. Under hard dependency, all the methods that the test depends on must run and succeed. If a failure happens to occur, the testNG method will fail. However, under soft dependency testNG will still run even after some methods it depends on have failed. Thus, soft dependency is preferable over hard dependency.
Resource: http://www.automation-simplified.com/articles/testng-tutorial.html

Total Views: 234Word Count: 563See All articles From Author

Add Comment

Computers Articles

1. Find Your Perfect Device At The Best Acer Store Near Me – Explore Acer Aspire In Chennai
Author: Prachi Grey

2. Case Study: Enhance Customer Satisfaction Using Deliveroo Food Delivery Scraping
Author: Food Data Scrape

3. Custom Wordpress Plugin Development: Why It’s Essential For A High-performance Website
Author: Egrove Systems

4. How To Create An Email Marketing Plan That Works?
Author: goodcoders

5. How To Create An E-learning Platform Like Udemy And Coursera?
Author: goodcoders

6. Build A Strong Online Presence With Wordpress: Celebrate The Content With A Professional Wordpress Website Development Agency
Author: Egrove Systems

7. Top Features To Look For In An Invoice Management Tool In 2025
Author: sneha

8. Boost Accuracy And Efficiency With Sales Order Management Tools
Author: vishva

9. Real Time Cricket Score Trends Via Crex Data Scraping
Author: Retail Scrapes

10. Unlocking Digital Excellence: The Value Of Professional Wordpress Developer Services
Author: Egrove Systems

11. The 7 Most Important Seo Tips For Higher Rankings
Author: Akshay Sharma

12. Effortless Ordering: How Cloud-based Purchase Order Solutions Streamline Procurement
Author: sneha

13. Why Wordpress Remains The Top Choice For Website Development In 2025
Author: Egrove Systems

14. Making Ai Chatbots Simple For Everyone
Author: davidbeckam

15. Scraping Mcdonalds Menu Prices And Items Data
Author: Food Data Scrape

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: