Table of Contents

Class AuditsAdapter

Namespace
OpenQA.Selenium.DevTools.V147.Audits
Assembly
Selenium.WebDriver.dll

Represents an adapter for the Audits domain to simplify the command interface.

public class AuditsAdapter
Inheritance
AuditsAdapter
Inherited Members

Constructors

AuditsAdapter(IDevToolsSession)

Initializes a new instance of the AuditsAdapter class.

public AuditsAdapter(IDevToolsSession session)

Parameters

session IDevToolsSession

The IDevToolsSession to be used with this adapter.

Exceptions

ArgumentNullException

If session is null.

Properties

Session

Gets the DevToolsSession associated with the adapter.

public IDevToolsSession Session { get; }

Property Value

IDevToolsSession

Methods

CheckFormsIssues(CheckFormsIssuesCommandSettings?, CancellationToken, int?, bool)

Runs the form issues check for the target page. Found issues are reported using Audits.issueAdded event.

public Task<CheckFormsIssuesCommandResponse> CheckFormsIssues(CheckFormsIssuesCommandSettings? command = null, CancellationToken cancellationToken = default, int? millisecondsTimeout = null, bool throwExceptionIfResponseNotReceived = true)

Parameters

command CheckFormsIssuesCommandSettings
cancellationToken CancellationToken
millisecondsTimeout int?
throwExceptionIfResponseNotReceived bool

Returns

Task<CheckFormsIssuesCommandResponse>

Disable(DisableCommandSettings?, CancellationToken, int?, bool)

Disables issues domain, prevents further issues from being reported to the client.

public Task<DisableCommandResponse?> Disable(DisableCommandSettings? command = null, CancellationToken cancellationToken = default, int? millisecondsTimeout = null, bool throwExceptionIfResponseNotReceived = true)

Parameters

command DisableCommandSettings
cancellationToken CancellationToken
millisecondsTimeout int?
throwExceptionIfResponseNotReceived bool

Returns

Task<DisableCommandResponse>

Enable(EnableCommandSettings?, CancellationToken, int?, bool)

Enables issues domain, sends the issues collected so far to the client by means of the issueAdded event.

public Task<EnableCommandResponse?> Enable(EnableCommandSettings? command = null, CancellationToken cancellationToken = default, int? millisecondsTimeout = null, bool throwExceptionIfResponseNotReceived = true)

Parameters

command EnableCommandSettings
cancellationToken CancellationToken
millisecondsTimeout int?
throwExceptionIfResponseNotReceived bool

Returns

Task<EnableCommandResponse>

GetEncodedResponse(GetEncodedResponseCommandSettings, CancellationToken, int?, bool)

Returns the response body and size if it were re-encoded with the specified settings. Only applies to images.

public Task<GetEncodedResponseCommandResponse> GetEncodedResponse(GetEncodedResponseCommandSettings command, CancellationToken cancellationToken = default, int? millisecondsTimeout = null, bool throwExceptionIfResponseNotReceived = true)

Parameters

command GetEncodedResponseCommandSettings
cancellationToken CancellationToken
millisecondsTimeout int?
throwExceptionIfResponseNotReceived bool

Returns

Task<GetEncodedResponseCommandResponse>

Events

IssueAdded

issueAdded

public event EventHandler<IssueAddedEventArgs>? IssueAdded

Event Type

EventHandler<IssueAddedEventArgs>