Table of Contents

Class XpingAssertions

Namespace
Xping.Sdk
Assembly
Xping.Sdk.dll

The XpingAssertions class provides static methods for assertion validation that can be used to make assertions state in the tests.

public abstract class XpingAssertions
Inheritance
XpingAssertions
Inherited Members

Methods

Expect(ILocator)

Creates an instance of Microsoft.Playwright.ILocatorAssertions for the specified locator.

protected static ILocatorAssertions Expect(ILocator locator)

Parameters

locator ILocator

The Microsoft.Playwright.ILocator instance to be validated. Must not be null.

Returns

ILocatorAssertions

An instance of Microsoft.Playwright.ILocatorAssertions that provides assertions for the specified locator.

Exceptions

ArgumentNullException

Thrown when the locator is null.

Expect(IPage)

Creates an instance of Microsoft.Playwright.IPageAssertions for the specified browser Page.

protected static IPageAssertions Expect(IPage page)

Parameters

page IPage

The Microsoft.Playwright.IPage instance to be validated. Must not be null.

Returns

IPageAssertions

An instance of Microsoft.Playwright.IPageAssertions that provides assertions for the specified page.

Exceptions

ArgumentNullException

Thrown when the page is null.

Expect(IHtmlContent)

Creates an instance of IHtmlAssertions for the specified HTML response.

protected static IHtmlAssertions Expect(IHtmlContent htmlContent)

Parameters

htmlContent IHtmlContent

The HTML response to be validated. Must not be null.

Returns

IHtmlAssertions

An instance of IHtmlAssertions for performing assertions on the HTML response.

Expect(IHtmlLocator)

Creates an instance of IHtmlLocatorAssertions for the specified HTML response.

protected static IHtmlLocatorAssertions Expect(IHtmlLocator htmlLocator)

Parameters

htmlLocator IHtmlLocator

The HTML locator response to be validated. Must not be null.

Returns

IHtmlLocatorAssertions

An instance of IHtmlLocatorAssertions for performing assertions on the HTML locator response.

Expect(IHttpResponse)

Creates an instance of IHttpAssertions for the specified HTTP response.

protected static IHttpAssertions Expect(IHttpResponse httpResponse)

Parameters

httpResponse IHttpResponse

The HTTP response to be validated. Must not be null.

Returns

IHttpAssertions

An IHttpAssertions instance for performing assertions on the HTTP response.