Here creating an executable performance test are extremely tool-specific. Regardless of the tool that you are using, creating a performance test typically involves taking a single instance of your test script and gradually adding more instances and/or more scripts over time, thereby increasing the load on the component or system.
To determine how many instances of a script are necessary to accomplish the objectives of your test, you first need to identify a workload that appropriately represents the usage scenario related to the objective.
Finding Workload of Combined User Scenarios
A workload profile consists of an aggregate mix of users performing various operations. Consider the following activities to identifying the workload:
Identify the distribution (ratio of work). For each key scenario, identify the distribution / ratio of work. The distribution is based on the number of users executing each scenario, based on your application scenario.
Identify the peak user loads. Identify the maximum expected number of concurrent users of the Web application. Using the work distribution for each scenario, calculate the percentage of user load per key scenario.
Identify the user loads under a variety of conditions of interest. For instance, you might want to identify the maximum expected number of concurrent users for the Web application at normal and peak hours.
Creating the Performance Test
After you have identified the workload for each user scenario to be tested, create your performance test by performing the following activities:
Create a performance test that will take a single instance of the test script that corresponds to the user scenario to be tested. Later, more instances will be added for each additional scenario.
Gradually add more instances over time, increasing the load for the user scenario to the maximum workload identified in the above step. It is important to allow sufficient time between each s increase in the number of users, so that the system has enough time to stabilize before the next set of user connections executes the test case.
Integrate measurement of resource utilization of interest on the server(s): for example, CPU, Memory, Disk, and Network.
If possible, set thresholds in your testing tool according to your performance test objectives; for example, the resource utilization thresholds can be as follows:
1) Processor\% Processor Time: 75 percent
2) Memory\Available MBytes: 25 percent of total physical RAM
Consider some key points when implementing test scripts to meet business requirements:
Test data feeds implemented correctly being consumed by the test script
Application data feeds implemented in the database or other server like email, message queue etc to simulate business scenarios. For example placing an order with volume of orders pending shipment.
Validation rules implemented. Some Web server requests return success error code, but transactions fail to complete.
Extraction rules implemented. Some session data and other response hidden fields are returned, and need to be submitted in subsequent requests. Consider handling such data correct, otherwise transactions will fail.
Key performance indicators. Work with those indicators in load tests, so load test result analysis can be done.
Business performance indicators. Add pertinent indicators that will facilitate articulating business performance. For examples creating a transaction around orders submittal will give you relevant volume per given time, that you will be able to read from load test results.
Related Topics: