56.2. Load Tests

While web and load testing are meant to test functional requirements, Load Tests will run a set of tests repeatedly so you can see how your application will perform. To create a Load Test, right-click your test project and select Load Test from the Add sub-menu. This will present you with a wizard that will guide you through the necessary steps. First, you'll need to create a scenario; here you will define if you want to use think times. When you recorded the Web Tests, the time you took between each request was also recorded and can be used as the think time. It can be edited for each Web Test request in the properties window.

As part of the scenario you will define the load pattern; for example, a constant load of 100 users or a load incrementing by 10 every 10 seconds until you get to 200 users. The next steps, Test, Browser, and Network Mix, define how tests will be run by virtual users according to Test Mix, specifying which browsers are used and simulating which kind of networks. In the Test Mix step you can add Generic, Ordered, and Web Tests.

Finally, in the Counter Sets step, you add the computers that you want to monitor and the performance counters you are interested in. For example, you can monitor your Database Server and IIS. In the last step, Run Settings, you can specify the test duration or test iterations, how often samples will be taken for performance counters, a test description, how many identical errors will be recorded, and the validation ...

Get Professional Visual Studio® 2008 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.