Load Testing                                                                                        
•        A load test is where one or more “non-manual” tests in a test group are performed while simulating
multiple users interacting with the application(s).
-        A load test can include web, unit, database unit, generic and ordered testing.
-        When the test is performed, information on the results is created.
•        Remember: Windows XP with IIS 5.1 and the Development web server bundled with VS.NET allow
limited connections.
-        For most accurate results, Load tests should never be performed on the same machine as the web server.
•        There are different types of load tests, which allow you to check how well the application(s) perform
under light or heavy loads.
-        A “smoke test” simulates a light load for a short duration
-        A “stress test” tests the application(s) under heavy stress for an extended period.
-        A “performance test” determines how responsive the application performs.
-        A “capacity planning” test determines how well the application runs in different environments.

Adding a Load Test                                                                                
•        In order to create a load test, you need to step through the Load Test Wizard.
-        This wizard helps you create a load scenario, which allows you to group your tests and set various load
properties concerning how the tests will be performed on your application(s).
-        The load properties include the number of simultaneous users, think times, web browsers used, the
network configuration, etc.
•        Adding a load test is similar to adding any of the other types of tests – just right click the test project
and choose Add – New Test.
-        Alternatively, you can add the load test menu item directly from the Add menu, without needing to
bring up the “Add New Test” dialog box.
-        Note that not all test types are shown in the Add menu. If you always want to see all the tests, choose
New Test from the Add menu.

•        Here is the Load Test Wizard in all its Glory:


-        Notice that the scenario is used to group the load pattern, the list of tests and the browser and network
configurations.
•        Give the scenario (test group) a meaningful name. Keep in mind; you can add additional scenarios as
needed.


-        You can also set up whether or not you want to use “think times”. Think times simulate a user pausing
between web clicks.
•        The Load Pattern is used to specify how many users are to be simulated.


-        Interestingly, the Step load option can be used to gradually increase the simulated user count testing the
web site.
•        Albeit disabled, let’s consider the values in the illustration above.
-        When the web test starts, it will initially have 10 users hitting the site.
-        Every 10 seconds, another 10 users will join in on the load testing.
-        There is a maximum of 200 users that will be used in the test.

•        The next dialog lets you choose which test(s) is used.


-        By clicking “Add…” you choose which tests in your test project are to be included.
-        You can also specify a percentage distribution for your tests. This is helpful if you are load testing
several tests at the same time.

•        The next two dialogs allow you to add additional web browser types and choose which network type
to simulate.
-        Mind you, the web browsers list is still missing two popular web browsers, Mozilla and Opera.
-        You will add these web browsers to TFS’s configuration in the lab.
-        Generally, when selecting more than one network, you should simulate having a higher percentage of
faster connected networks (DSL, T1) than slower (Dialup 28.8k, for example) networks.
•        The Counter Sets dialog is used to add specific load testing performance counters to the tests.
-        You need to add one or more computers that you wish to monitor via performance counters.
-        You can also use Microsoft Team Test Load Agent with its performance counters on remote machines
for more accurate test results.
•        Once completed, your test configuration should look something like this:


•        You can change any of your settings that you’d like. When you run the test, you’ll see something like
this:


-        At the top, there are buttons that read Stop, Graphs (currently selected) and Tables. Clicking on Tables
gives just the raw data.

•        Apparently, this web application is showing quite a few errors! Not good.


-        Looking at the results, you can see the test received over 1000 different web 403 errors.
-        This is probably due to the fact this was run against the web development server bundled with Visual
Studio.
-        For more accurate results, deploy to Windows 2003 with IIS 6.
Load Testing
Table of Contents
Copyright (c) 2008.  Intertech, Inc. All Rights Reserved.  This information is to be used exclusively as an
online learning aid.  Any attempts to copy, reproduce, or use for training is strictly prohibited.
Courseware
Training Resources
Tutorials