What is Endurance Testing in Software Testing? (with Example)
Endurance Testing is non-functional type of software testing where a software is tested with high load extended over a significant amount of time to evaluate the behavior of software application under sustained use. The main purpose of endurance testing is to ensure that the application is capable enough to handle extended load without any deterioration of response time.
This type of testing is performed at the last stage of the performance run cycle. Endurance testing is a long process and sometimes lasts for even up to a year. This may include applying external loads such as Internet traffic or user actions. This makes endurance testing differ from Load Testing, which usually ends in a couple of hours or so.
Endurance means capacity so in other words, you can term Endurance Testing as Capacity Testing.
Primary goal of Endurance testing is to check for memory leaks.
To discover how the system performs under sustained usage.
To ensure that after a long period, the system response time will remain the same or better than the start of the test.
To determine the number of users and/or transactions a given system will support and meet performance goals.
To manage the future loads, we need to understand how many additional resources (like processor capacity, disk capacity, memory usage, or network bandwidth) are necessary to support usage in future.
Endurance testing is generally done by either overloading the system or by reducing certain system resources and evaluating the consequences.
It is performed to ensure that defects or memory leaks do not occur after what is considered to be a relatively "normal" usage period.
What to monitor in Endurance Testing
In Endurance Testing following things are tested.
Test memory leakage- Checks are done to verify if there is any memory leakage in the application, which can cause crashing of the system or O.S.
Test connection closure between the layer of the system – If the connection between the layers of the system is not closed successfully, it may stall some or all modules of the system.
Test database connection close successfully- If the database connection is not closed successfully, may result in system crash
Test response time – System is tested for the response time of the system as the application becomes less efficient as a result of the prolonged use of the system.
How to perform Endurance Testing
Below is the basic testing approach for Endurance Test
Testing Environment – Identify the hardware, software, operating system require for the endurance testing, assigning roles and responsibilities within the team, etc. The environment should be ready before the test execution. You also need to estimate common database production size and yearly growth. This is required as such you need to test how your application will respond after a year, two or five.
Creating the Test Plan, Scenarios - Based on nature of testing - manual or automation or combination of both, Test Case design, reviews, and execution should be planned. Testing to stress the system, break point testing, etc. should also be part of the test plan. Testing to stress the system determines the break point in the application.
Test Estimation – Provide the estimation of how long it will take to complete the testing phase. It should be analyzed on the basis of a number of testers involved and the number of test cycles required.
Risk Analysis - Analyzing the risk and taking an appropriate action for the prevention. Prioritization of test cases as per the Risk factor and identify the below risk and issues tester may phase during the endurance test.
Will performance remain consistent over time?
Are there other minor issues that have not yet been detected?
Is there external interference that was not addressed?
Test Schedule - Determine the budget, deliverables within the time frames. As Endurance Testing applies a huge but natural load arrangement of transactions to the system/application for a continuous period of time.
Endurance Testing Example
While Stress testing takes the tested system to its limits, Endurance testing takes the application to its limit over time.
For Example, the most complex issues – memory leaks, database server utilization, and unresponsive system – happen when software runs for an extended period of time. If you skip the endurance tests, your chances of detecting such defects prior to deployment are quite low.