As the name suggests, Concurrency means two or more events happening at the same time. Similarly, concurrence testing is done to identify how the application will be affected when multiple users are logged in at the same time and doing the same action. Concurrency Testing is also known as multi-user testing.
When multiple users are performing the same action at the same time then there can be issues like increased response time, application crashes etc. which are detected by concurrence testing. Concurrence testing helps improving reliability and robustness of concurrent programs. Concurrent programs run a number of the program at the same time and involved in sharing information. The sharing of information controls the order of execution of tasks. If there is any change in the sequence of execution of these processes then it produces incorrect results which result in repeatability of error. Concurrent testing ensures the reliability of concurrent programs. A real-time example of concurrency is: Trains running on the different track at the same time or train running in same track at different timings.
Concurrency Testing Process:
- Creating a plan for concurrent testing.
- Analyzing the plan and defining scope.
- Creating a High level and low-level scenarios for concurrent testing.
- Creating the environment for testing.
- Now, testers two or more testers can begin the testing by performing the same task at the same timings.
In load runner, a Rendezvous point is used to create concurrency. The tester can create a scenario after recording and enhancing script in Visual User Generator. In the controller component of load runner, the tester can add a number of concurrent users.
All the users involved in the testing can wait at the same point (For example Login Button), all the users can press the login button at the same time. (Rendezvous point).
These days due to increase in a number of internet users, there is a possibility that a web server may be handling many different clients at the same time, in such types of situation server can go to a deadlock state as it is handling multiple users at the same point. To make sure this flow should go smooth and there should be no deadlock, concurrency testing is done.
Concurrency Testing Techniques:
- Reviewing code: In this process embedded code and their structures are checked. This is a time-consuming process.
- Static Analysis: Static analysis is used for checking and evaluating coding system before executing the code. It is useful in detecting bugs and errors in the system.
- Con Testing: Contest removes synchronization faults in multithreaded java program. The contest also notes the deficiencies in unit testing.
- Reachability Testing: Reachability testing is usually not possible for many applications as it needs large subtests. There are some proposed research programs to make reachability testing more useful for concurrent testing.
- Fuzz Testing: In this testing, user feeds random incorrect data and then wait to see how the program responds. There is no logic behind fuzz testing, it is more of a guess where bad data is provided to crash a program.
- Random testing: Coverage area is increased by randomizing test inputs. Multiple threads are tested at one time. For better results, 5-10 threads should be tested at a time.
- Extending concolic testing: This can be used for testing multi-threaded or concurrent programs. This type of testing is easily extendable and expendable with flipping algorithms. Without an extension, concolic testing is effective for testing sequential program.
Key Challenges in Concurrency Testing:
- The test case creation for Concurrency Testing is time-consuming and a very tough job which requires the regular help of the developers.
- During concurrent testing, there are very high chances that new errors are introduced in code.
- Concurrent testing needs to be done on different platforms.
- This testing is more difficult as function return their results via notifications or call back functions instead of delivering immediately.
- Debugging of the concurrent program.
- The ratio of failure of Concurrency Testing is much more than the sequential program.
- Most of the defects are time related and difficult to reproduce.
Over to you:
- Concurrency Testing – To check the effect on the system when multiple users are logged in performing the same task at the same time.
- Help in removing robustness of concurrent programs.
- Used to detect issues like deadlock, increased response time, application crashes.
If you are not a regular reader of this website then highly recommends you Sign up for our free email newsletter!! Sign up just providing your email address below:
Happy Testing!!!
- What is Scalability Testing in Performance Testing?
- What is Soak Testing in Software Testing?
- What is Exploratory Testing?
- What is Performance Testing?
- How to do Performance Testing using JMeter? – JMeter Tutorials Series Day 5
- What is Mutation Testing? – Tools, Testing Types And It’s Challenges
- Overview Of Performance Testing With VSTS
- Starting Performance Testing: What Metrics To Use?
- Model Based Testing: Testing Type You Must Know!
- Essential Elements in the IoT Software Testing