Skip to main content

Target class

This class provides methods that are used to define the top level target (the entire window, region, element, frame, etc.) for the Check method.

Once you create a CheckSettings object using one of the factory methods defined by this class, you can configure the checkpoint by calling other methods from the CheckSettings class, chaining them one after the other using the '.' operator.

Using statement​

using Applitools.Selenium;

Frame method​

Syntax​

eyes.Check(Target.Frame(by))
eyes.Check(Target.Frame(frameNameOrId))
eyes.Check(Target.Frame(index))
eyes.Check(Target.Frame(frameReference))

Note: This method is a static method.

Parameters​

by

Type: By

An element selector which is chosen using the Selenium By class.

frameNameOrId

Type: string

The name or id of the frame element.

index

Type: int

The index of the iframe (as in Selenium By Index).

frameReference

Type: IWebElement

A reference to the frame element.

Return value​

Type: CheckSettings

Region method​

Syntax​

eyes.Check(Target.Region(rect))
eyes.Check(Target.Region(element))
eyes.Check(Target.Region(by))

Note: This method is a static method.

Parameters​

rect

Type: Rectangle

An object that defines a rectangular area in the window.

element

Type: IWebElement

An object which defines a region.

by

Type: By

An element selector which is chosen using the Selenium By class.

Return value​

Type: CheckSettings

Window method​

Syntax​

eyes.Check(Target.Window())

Note: This method is a static method.

Parameters​

This method does not take any parameters.

Return value​

Type: CheckSettings