Skip to Main Content
Professional Visual Studio® 2008
book

Professional Visual Studio® 2008

by Nick Randolph, David Gardner
July 2008
Intermediate to advanced content levelIntermediate to advanced
1026 pages
27h 59m
English
Wrox
Content preview from Professional Visual Studio® 2008

56.1. Web Tests

These tests will simulate web requests and allow you to inspect the responses and evaluate different conditions to determine if the test passes. To create a new Web Test, right-click your Test Project from the Add submenu and select Web Test. This will open Internet Explorer with the Web Test Recorder enabled as shown in Figure 56-1. Point to your site as if you were a normal user and interact with your application. Once done, simply click Stop. This will open the Web Test's designer shown in Figure 56-2. There you can customize your test, adding validation and extraction rules, context parameters, comments, data sources, and calls to other Web Tests, or inserting transactions.

You will often need to run the same set of tests against different web servers; to do this you configure this as a context parameter. From the Web Test Designer you can right-click the main node and select Parameterize Web Servers. Visual Studio will inspect the URLs in each request and determine the context parameters it will need to create.

You can link your requests using the output from one of them as input for the next; to do this you add extraction rules to a specific request. You can extract from fields, attributes, http headers, hidden fields, and text, or even use regular expressions. The result of an extraction will set a context parameter, which can then be used, for example, as a form or query string parameter in further requests. You could add a product and then search for it ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Professional Visual Studio® 2010

Professional Visual Studio® 2010

Nick Randolph, David Gardner, Michael Minutillo, Chris Anderson

Publisher Resources

ISBN: 9780470229880Purchase book