Class TestAgentExtensions
- Namespace
- Xping.Sdk.Extensions
- Assembly
- Xping.Sdk.dll
Provides extension methods for the TestAgent class to enhance its functionality.
public static class TestAgentExtensions
- Inheritance
-
TestAgentExtensions
- Inherited Members
Methods
UseBrowserClient(TestAgent, Action<BrowserConfiguration>?)
Configures the TestAgent to simulate browser requests.
public static TestAgent UseBrowserClient(this TestAgent testAgent, Action<BrowserConfiguration>? options = null)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
optionsAction<BrowserConfiguration>Optional configuration settings for the browser simulation.
Returns
UseDnsLookup(TestAgent)
Configures the TestAgent to perform DNS lookups.
public static TestAgent UseDnsLookup(this TestAgent testAgent)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
Returns
UseHtmlValidation(TestAgent, Action<IHtmlContent>)
Configures the TestAgent with a html content validator.
public static TestAgent UseHtmlValidation(this TestAgent testAgent, Action<IHtmlContent> htmlContent)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
htmlContentAction<IHtmlContent>The validation logic to use on the Html content.
Returns
UseHttpClient(TestAgent, Action<HttpClientConfiguration>?)
Configures the TestAgent to send requests using an HttpClient.
public static TestAgent UseHttpClient(this TestAgent testAgent, Action<HttpClientConfiguration>? options = null)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
optionsAction<HttpClientConfiguration>Optional configuration settings for the HttpClient.
Returns
UseHttpValidation(TestAgent, Action<IHttpResponse>)
Configures the TestAgent with a http response validator.
public static TestAgent UseHttpValidation(this TestAgent testAgent, Action<IHttpResponse> response)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
responseAction<IHttpResponse>The validation logic to use on the HTTP response.
Returns
UseIPAddressAccessibilityCheck(TestAgent, Action<PingConfiguration>?)
Configures the TestAgent to check IP address accessibility using ping.
public static TestAgent UseIPAddressAccessibilityCheck(this TestAgent testAgent, Action<PingConfiguration>? options = null)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
optionsAction<PingConfiguration>Optional configuration settings for the ping operation.
Returns
UsePageValidation(TestAgent, Func<IPage, Task>)
Configures the TestAgent with a page content validator.
public static TestAgent UsePageValidation(this TestAgent testAgent, Func<IPage, Task> page)
Parameters
testAgentTestAgentThe instance of TestAgent to configure.
pageFunc<IPage, Task>The validation logic to use on the Page object.