Class: PlaywrightInteractor
@atomic-testing/playwright.PlaywrightInteractor
Implements
Interactor
Constructors
constructor
• new PlaywrightInteractor(page
): PlaywrightInteractor
Parameters
Name | Type |
---|---|
page | Page |
Returns
Defined in
Properties
page
• Readonly
page: Page
Defined in
Methods
click
▸ click(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <ClickOption > |
Returns
Promise
<void
>
Implementation of
Interactor.click
Defined in
clone
▸ clone(): Interactor
Returns
Interactor
Implementation of
Interactor.clone
Defined in
enterText
▸ enterText(locator
, text
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
text | string |
option? | Optional <Partial <EnterTextOption >> |
Returns
Promise
<void
>
Implementation of
Interactor.enterText
Defined in
exists
▸ exists(locator
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<boolean
>
Implementation of
Interactor.exists
Defined in
focus
▸ focus(locator
, _option
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
_option | Partial <FocusOption > |
Returns
Promise
<void
>
Implementation of
Interactor.focus
Defined in
getAttribute
▸ getAttribute(locator
, name
, isMultiple
): Promise
<readonly string
[]>
Parameters
Name | Type |
---|---|
locator | PartLocator |
name | string |
isMultiple | true |
Returns
Promise
<readonly string
[]>
Implementation of
Interactor.getAttribute
Defined in
▸ getAttribute(locator
, name
, isMultiple
): Promise
<Optional
<string
>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
name | string |
isMultiple | false |
Returns
Promise
<Optional
<string
>>
Implementation of
Interactor.getAttribute
Defined in
▸ getAttribute(locator
, name
): Promise
<Optional
<string
>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
name | string |
Returns
Promise
<Optional
<string
>>
Implementation of
Interactor.getAttribute
Defined in
getInputValue
▸ getInputValue(locator
): Promise
<Optional
<string
>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<Optional
<string
>>
Implementation of
Interactor.getInputValue
Defined in
getSelectLabels
▸ getSelectLabels(locator
): Promise
<Optional
<readonly string
[]>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<Optional
<readonly string
[]>>
Implementation of
Interactor.getSelectLabels
Defined in
getSelectValues
▸ getSelectValues(locator
): Promise
<Optional
<readonly string
[]>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<Optional
<readonly string
[]>>
Implementation of
Interactor.getSelectValues
Defined in
getStyleValue
▸ getStyleValue(locator
, propertyName
): Promise
<Optional
<string
>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
propertyName | CssProperty |
Returns
Promise
<Optional
<string
>>
Implementation of
Interactor.getStyleValue
Defined in
getText
▸ getText(locator
): Promise
<Optional
<string
>>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<Optional
<string
>>
Implementation of
Interactor.getText
Defined in
hasAttribute
▸ hasAttribute(locator
, name
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
name | string |
Returns
Promise
<boolean
>
Implementation of
Interactor.hasAttribute
Defined in
hasCssClass
▸ hasCssClass(locator
, className
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
className | string |
Returns
Promise
<boolean
>
Implementation of
Interactor.hasCssClass
Defined in
hover
▸ hover(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <HoverOption > |
Returns
Promise
<void
>
Implementation of
Interactor.hover
Defined in
isChecked
▸ isChecked(locator
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<boolean
>
Implementation of
Interactor.isChecked
Defined in
isDisabled
▸ isDisabled(locator
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<boolean
>
Implementation of
Interactor.isDisabled
Defined in
isReadonly
▸ isReadonly(locator
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<boolean
>
Implementation of
Interactor.isReadonly
Defined in
isVisible
▸ isVisible(locator
): Promise
<boolean
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
Returns
Promise
<boolean
>
Implementation of
Interactor.isVisible
Defined in
mouseDown
▸ mouseDown(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <MouseDownOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseDown
Defined in
mouseEnter
▸ mouseEnter(locator
, _option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
_option? | Partial <MouseEnterOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseEnter
Defined in
mouseLeave
▸ mouseLeave(locator
, _option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
_option? | Partial <MouseLeaveOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseLeave
Defined in
mouseMove
▸ mouseMove(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <MouseMoveOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseMove
Defined in
mouseOut
▸ mouseOut(locator
, _option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
_option? | Partial <MouseOutOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseOut
Defined in
mouseOver
▸ mouseOver(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <HoverOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseOver
Defined in
mouseUp
▸ mouseUp(locator
, option?
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
option? | Partial <MouseUpOption > |
Returns
Promise
<void
>
Implementation of
Interactor.mouseUp
Defined in
selectOptionValue
▸ selectOptionValue(locator
, values
): Promise
<void
>
Parameters
Name | Type |
---|---|
locator | PartLocator |
values | string [] |
Returns
Promise
<void
>
Implementation of
Interactor.selectOptionValue
Defined in
wait
▸ wait(ms
): Promise
<void
>
Parameters
Name | Type |
---|---|
ms | number |
Returns
Promise
<void
>
Implementation of
Interactor.wait