|
In this section, you will learn how to develop and execute web load test cases using Web Performance test Studio using the sample application Employee Scheduler. The basic steps involved in Web Load testing are as follows:
Recording the list of actions that a user performs on the web site.
Parameterize the user data, URL and its parameters.
Configure workloads and load tests.
Execute the load test with the specified load conditions.
Step 1: Creating New Suite
To create a new suite, choose New Suite option from the links placed below the top frame. In the dialog, specify the name of the new suite, application name, version and click the OK button. The new suite will be displayed in the tree.
Step 2: Creating New Load Test
The next step is creating a new load test in the newly-created suite. Select the 'Add New Load Test' option under '[Suite Name]->Load Tests' from the left-side tree. The 'Create New Load Test' dialog box will be shown. Enter the name for the load test and click OK button to create a new load test. The newly created load test will be listed under '[SuiteName]->loadtests' on the left side tree.
Step 3: Creating a Transaction
A transaction is the set of user actions performed on the web site which are recorded as URLs. To create a transaction,
Select the suite and the load test under which you want to create the transaction.
Choose New Transaction option from the screen displayed on the right side. In the dialog, specify the name of the new transaction and click the OK button. The transaction will be saved by default under <QEngine_Home>/projects/<Suite_Name>/webperfcases/<businesscase_name> directory. For example, enter "view_acct_balance". You will see the new transaction node added under the tree node labeled "businesscase".
After creating a transaction, you need to record the user actions on the web site. Choose the Launch Browser option from the QEngine toolbar to launch the browser. The default browser will be launched. Specify a valid URL in the launched browser and choose the Start Record toolbar option from the QEngine toolbar to start recording the transactions (urls) in the Web application.
Step 4: Parameterizing user specific data
Parameterization lets you use a different login name and password for each virtual user (dynamic substitution of values). There’s no need for each User Scenario to contain a separate script that performs the task of logging in. Similarly, you can parameterize the cookies and other headers passed in the request header such as Scheme, Proxy-Connection, etc. You can also parameterize the parameters passed with the URL string.
Step 5: Load Test Configuration
A load test definition involves recording transactions, and defining and associating workloads to the load test.
Workload defines the number of users along with the rate or interval at which the users execute the transaction.
Step 6: Start Play
To run the performance test or playback, select a transaction, choose
the Start Play option from the
QEngine toolbar. This displays the Play Status UI.
From the TestCase field, select the load test to be executed and click the Start Play button.
Web Application under test (Sample Suite - WebPerformanceDemo)
To illustrate how one can test the performance of a web site, a sample test suite named WebPerformanceDemo for Employee Scheduler application has been already developed and bundled with the product and placed in <QEngine Home>/projects/WebPerformanceDemo folder. You can access it from the Suite Manager screen. Execute the load tests one by one and get a feel of them.
Employee Scheduler is an open source application available freely on the web. This application was developed to reduce the effort of employers in scheduling an appropriate work time for the employees.
In this application, the employer or the supervisor can login and create user logins for the employees. The employees can then connect to the application and specify their work schedules. Based on the work schedules specified by the employees, the supervisor can allocate appropriate work schedules. This application mainly caters to work scheduling for part-time employees of a company.
The sample suite WebPerformanceDemo has some default load tests. These load tests illustrate some of the important features of Web Performance Test Studio. Follow the below given links for the related documents:
|