Stress Testing | Software Testing
Prerequisite – Types of Software Testing
Stress Testing is a software testing technique that determines the robustness of software by testing beyond the limits of normal operation. Stress testing is particularly important for critical software but is used for all types of software. Stress testing emphasizes robustness, availability, and error handling under a heavy load rather than what is correct behavior under normal situations. Stress testing is defined as a type of software testing that verifies the stability and reliability of the system. This test particularly determines the system on its robustness and error handling under extremely heavy load conditions. It even tests beyond the normal operating point and analyses how the system works under extreme conditions. Stress testing is performed to ensure that the system would not crash under crunch situations. Stress testing is also known as Endurance Testing or Torture Testing.
Characteristics of Stress Testing:
- Stress testing analyzes the behavior of the system after a failure.
- Stress testing makes sure that the system recovers after failure.
- It checks whether the system works under abnormal conditions.
- It ensures to display of appropriate error messages when the system is under stress.
- It verifies that unexpected failures do not cause security issues.
- It verifies whether the system has saved the data before crashing or not.
Stress Testing Process: Types of Stress Testing:
- Server-client Stress Testing: In this stress testing, testing is carried out across all clients from the server.
- Product Stress Testing: Product stress testing concentrates on discovering defects related to data locking and blocking, network issues, and performance congestion in a software product.
- Transaction Stress Testing: Transaction stress testing is performed on one or more transactions between two or more applications. It is carried out for fine-tuning and optimizing the system.
- Systematic Stress Testing: Systematic stress testing is integrated testing that is used to perform tests across multiple systems running on the same server. It is used to discover defects where one application data blocks another application.
- Analytical Stress Testing: Analytical stress testing is performed to test the system with abnormal parameters or conditions that are unlikely to happen in a real scenario. It is carried out to find defects in unusual scenarios like a large number of users logged at the same time or a database going offline when it is accessed from a website.
Stress Testing Tools:
Metrics of Stress Testing :
Metrics are used to evaluate the performance of the stress and it is usually carried out at the end of the stress scripts or tests. Some of the metrics are given below.
- Pages Per Second: Number of pages requested per second and number of pages loaded per second.
- Pages Retrieved: Average time taken to retrieve all information from the particular page.
- Byte Retrieved: Average time is taken to retrieve the first byte of information from the page.
- Transaction Response Time: Average time is taken to load or perform transactions between the applications.
- Transactions per Second: It takes count of the number of transactions loaded per second successfully and it also counts the number of failures that occurred.
- Failure of Connection: It takes count of the number of times that the client faced the connection failure in their system.
- Failure of System attempts: It takes count of the number of failed attempts in the system.
- Rounds: It takes count of the number of test or script conditions executed by the clients successfully and it keeps track of the number of rounds failed.
Advantages of Stress Testing:
- Stress testing determines the behavior of the system after failure and ensures that the system recovers quickly.
- Stress testing ensures that system failure doesn’t cause security issues.
- Stress testing makes the system work in normal as well as abnormal conditions in an appropriate way.
Disadvantages of Stress Testing:
- The manual process of stress testing takes a longer time to complete and it is a complicated process.
- Good scripting knowledge for implementing the script test cases for the particular tool is required.
- There is a need for external resources to implement stress testing. It leads to an extra amount of resources and time.
- In the case of a licensed stress testing tool, it charges more than the average amount of cost.
- In the case of some open-source tools, there is a need for a load testing tool additionally for setting up the stress testing environment.
- If proper stress scripts or test cases are not implemented then there will be a chance of failure of some resources and wastage of time.