This documentation is archived and is not being maintained.

Microsoft.VisualStudio.TestTools.WebTesting Namespace

The Microsoft.VisualStudio.TestTools.WebTesting namespace supplies classes that enable Web testing. This namespace includes the WebTest class which is the base class for all Web tests. The WebTestRequest and WebTestResponse classes simulate the HTTP requests and responses of the Web pages under test. These classes use the FormPostHttpBody class to simulate the use of form post parameters. Microsoft.VisualStudio.TestTools.WebTesting also includes classes for data binding, test rules, identifying work items, query strings, HTTP context, and plug-ins that provide testing features.

Public classConnectionFailedWebTestExceptionAn exception that is thrown by the test engine for connection failure errors during a Web test.
Public classCssIterationAttributeRepresents the project iteration to which this test corresponds. This class cannot be inherited.
Public classCssProjectStructureAttributeRepresents the node in the team project hierarchy to which this test corresponds.
Public classDataBindingAttributeContains information that defines data binding properties for a Web test. This class cannot be inherited.
Public classDataSourceAttributeContains information that describes a data source for a Web test. This class cannot be inherited.
Public classDeploymentItemAttributeUsed to specify deployment items such as a file or directory for per-test-deployment. This class cannot be inherited.
Public classExtractionEventArgsProvides data for the ExtractValues event.
Public classExtractionRuleBase class used to define rules for obtaining data from a Web response that is generated by a Web test.
Public classFileUploadParameterRepresents a file upload form post parameter.
Public classFormPostHttpBodyRepresents an HTML form post body with a collection of form parameters.
Public classFormPostParameterRepresents an HTML form POST parameter.
Public classFormPostParameterCollectionRepresents a strongly typed container for form post parameters.
Public classHtmlAttributeRepresents an HTML attribute.
Public classHtmlAttributeWithOffsetsExtends the basic HtmlAttribute and tracks the beginning and ending offsets within an HTML document.
Public classHtmlDocumentProvides access to the set of HTML tags in an HTML response body.
Public classHtmlTagThe HtmlTag object is the foundation of the HTML document and holds the parsed structure of the document.
Public classHtmlTagWithOffsetsExtends the basic HtmlTag by tracking the beginning and ending tag offsets within the HTML document.
Public classOwnerAttributeUsed to specify the person responsible for maintaining, running, and/or debugging the test. This class cannot be inherited.
Public classParameterRepresents an HTTP parameter base class.
Public classPostRequestEventArgsProvides data for the WebTestRequest.PostRequest and WebTest.PostRequest events.
Public classPostWebTestEventArgsProvides data for the PostWebTest event.
Public classPreRequestEventArgsProvides data for the WebTest.PreRequest event.
Public classPreWebTestEventArgsProvides data for the PreWebTest event.
Public classPriorityAttributeUsed to specify the priority of a unit test. This class cannot be inherited.
Public classQueryStringParameterRepresents an HTTP querystring parameter.
Public classQueryStringParameterCollectionRepresents a strongly typed container for query string parameters.
Public classStringHttpBodyRepresents an HTTP body in string form used for SOAP support.
Public classTestDescriptionAttributeUsed to specify the description of the test. This class cannot be inherited.
Public classThreadedWebTestRepresents a base class for a coded Web test that uses a single thread per Web test iteration.
Public classTimeoutAttributeUse this attribute to specify the time-out period of a Web test.
Public classValidationEventArgsProvides data for the ValidateResponse event.
Public classValidationRuleVerifies that requests return valid HTTP responses and that the contents of the response match the expected results. This class must be inherited.
Public classWebTestBase class for all Web tests. Coded Web tests that are written in C# derive directly from this class.
Public classWebTestContextRepresents the context available to a WebTest.
Public classWebTestEndOfDataExceptionThe exception that is thrown when data binding is being performed on a table with the UniqueDataBindingAccessMethod when there are no more rows of data in the table.
Public classWebTestExceptionThe exception that is thrown by the test engine for errors that occur while a test is running.
Public classWebTestItemBase class for WebTestRequest.
Public classWebTestPluginProvides a means to run code and access a WebTest before and after the Web test is run. This class must be inherited.
Public classWebTestRequestRepresents an HTTP request that will be sent to a Web server.
Public classWebTestRequestCollectionA serializable, strongly typed container for Web test request headers.
Public classWebTestRequestHeaderRepresents an HTTP header.
Public classWebTestRequestHeaderCollectionA serializable strongly typed container for Web test request headers.
Public classWebTestRequestPluginReceives notifications before and after a request is processed.
Public classWebTestRequestStatisticsUsed to track key information that is gathered when the request is run.
Public classWebTestResponseRepresents an HTTP response.
Public classWorkItemAttributeUse this attribute to specify a work item that is associated with a test.

Public interfaceIHttpBodyProvides a common interface for accessing an HTTP body.

Public enumerationDataBindingAccessMethodEnumeration for the access method that is used for data binding.
Public enumerationValidationLevelUsed to identify the importance of a validation rule that is run in a load test.
Public enumerationWebTestExecutionInstructionUsed to denote how to handle an operation.