Documentation
¶
Index ¶
- Constants
- Variables
- func BlurAction(page playwrightgo.Page, action *ExecutorAction) error
- func CheckAction(page playwrightgo.Page, action *ExecutorAction) error
- func ClearAction(page playwrightgo.Page, action *ExecutorAction) error
- func ClickAction(page playwrightgo.Page, action *ExecutorAction) error
- func DoubleClickAction(page playwrightgo.Page, action *ExecutorAction) error
- func ExpectText(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeAttached(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeChecked(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeDisabled(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeEditable(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeEmpty(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeEnabled(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeFocused(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeHidden(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeInViewport(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToBeVisible(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToContainClass(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToContainText(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveAccessibleDescription(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveAccessibleErrorMessage(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveAccessibleName(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveAttribute(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveCSS(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveClass(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveId(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveJSProperty(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveValue(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToHaveValues(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func ExpectToMatchAriaSnapshot(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, ...) error
- func FillAction(page playwrightgo.Page, action *ExecutorAction) error
- func FocusAction(page playwrightgo.Page, action *ExecutorAction) error
- func GoBackAction(page playwrightgo.Page, action *ExecutorAction) error
- func GoForwardAction(page playwrightgo.Page, action *ExecutorAction) error
- func GotoAction(page playwrightgo.Page, action *ExecutorAction) error
- func PressAction(page playwrightgo.Page, action *ExecutorAction) error
- func PressSequentiallyAction(page playwrightgo.Page, action *ExecutorAction) error
- func RefreshAction(page playwrightgo.Page, action *ExecutorAction) error
- func ScreenshotAction(page playwrightgo.Page, action *ExecutorAction) error
- func SelectMultipleOptionsAction(page playwrightgo.Page, action *ExecutorAction) error
- func SelectOptionAction(page playwrightgo.Page, action *ExecutorAction) error
- func StubExpectAction(page playwrightgo.Page, action *ExecutorAction) error
- func TapAction(page playwrightgo.Page, action *ExecutorAction) error
- func UncheckAction(page playwrightgo.Page, action *ExecutorAction) error
- func UploadFileAction(page playwrightgo.Page, action *ExecutorAction) error
- func UploadMultipleFilesAction(page playwrightgo.Page, action *ExecutorAction) error
- func WaitForSelectorAction(page playwrightgo.Page, action *ExecutorAction) error
- func WaitForURLAction(page playwrightgo.Page, action *ExecutorAction) error
- type ActionFunc
- type AssertionFunc
- type Executor
- type ExecutorAction
- type Page
- type PageQuery
- type Result
Constants ¶
View Source
const Name = "playwright"
Variables ¶
View Source
var SupportedActions = actionMap
Functions ¶
func BlurAction ¶
func BlurAction(page playwrightgo.Page, action *ExecutorAction) error
func CheckAction ¶
func CheckAction(page playwrightgo.Page, action *ExecutorAction) error
func ClearAction ¶
func ClearAction(page playwrightgo.Page, action *ExecutorAction) error
func ClickAction ¶
func ClickAction(page playwrightgo.Page, action *ExecutorAction) error
func DoubleClickAction ¶
func DoubleClickAction(page playwrightgo.Page, action *ExecutorAction) error
func ExpectText ¶
func ExpectText(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeAttached ¶
func ExpectToBeAttached(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeChecked ¶
func ExpectToBeChecked(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeDisabled ¶
func ExpectToBeDisabled(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeEditable ¶
func ExpectToBeEditable(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeEmpty ¶
func ExpectToBeEmpty(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeEnabled ¶
func ExpectToBeEnabled(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeFocused ¶
func ExpectToBeFocused(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeHidden ¶
func ExpectToBeHidden(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeInViewport ¶
func ExpectToBeInViewport(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToBeVisible ¶
func ExpectToBeVisible(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToContainClass ¶
func ExpectToContainClass(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToContainText ¶
func ExpectToContainText(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveAccessibleDescription ¶
func ExpectToHaveAccessibleDescription(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveAccessibleErrorMessage ¶
func ExpectToHaveAccessibleErrorMessage(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveAccessibleName ¶
func ExpectToHaveAccessibleName(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveAttribute ¶
func ExpectToHaveAttribute(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveCSS ¶
func ExpectToHaveCSS(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveClass ¶
func ExpectToHaveClass(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveId ¶
func ExpectToHaveId(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveJSProperty ¶
func ExpectToHaveJSProperty(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveValue ¶
func ExpectToHaveValue(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToHaveValues ¶
func ExpectToHaveValues(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func ExpectToMatchAriaSnapshot ¶
func ExpectToMatchAriaSnapshot(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
func FillAction ¶
func FillAction(page playwrightgo.Page, action *ExecutorAction) error
func FocusAction ¶
func FocusAction(page playwrightgo.Page, action *ExecutorAction) error
func GoBackAction ¶
func GoBackAction(page playwrightgo.Page, action *ExecutorAction) error
func GoForwardAction ¶
func GoForwardAction(page playwrightgo.Page, action *ExecutorAction) error
func GotoAction ¶
func GotoAction(page playwrightgo.Page, action *ExecutorAction) error
func PressAction ¶
func PressAction(page playwrightgo.Page, action *ExecutorAction) error
func PressSequentiallyAction ¶
func PressSequentiallyAction(page playwrightgo.Page, action *ExecutorAction) error
func RefreshAction ¶
func RefreshAction(page playwrightgo.Page, action *ExecutorAction) error
func ScreenshotAction ¶
func ScreenshotAction(page playwrightgo.Page, action *ExecutorAction) error
func SelectMultipleOptionsAction ¶
func SelectMultipleOptionsAction(page playwrightgo.Page, action *ExecutorAction) error
func SelectOptionAction ¶
func SelectOptionAction(page playwrightgo.Page, action *ExecutorAction) error
func StubExpectAction ¶
func StubExpectAction(page playwrightgo.Page, action *ExecutorAction) error
func TapAction ¶
func TapAction(page playwrightgo.Page, action *ExecutorAction) error
func UncheckAction ¶
func UncheckAction(page playwrightgo.Page, action *ExecutorAction) error
func UploadFileAction ¶
func UploadFileAction(page playwrightgo.Page, action *ExecutorAction) error
func UploadMultipleFilesAction ¶
func UploadMultipleFilesAction(page playwrightgo.Page, action *ExecutorAction) error
func WaitForSelectorAction ¶
func WaitForSelectorAction(page playwrightgo.Page, action *ExecutorAction) error
func WaitForURLAction ¶
func WaitForURLAction(page playwrightgo.Page, action *ExecutorAction) error
Types ¶
type ActionFunc ¶
type ActionFunc func(page playwrightgo.Page, action *ExecutorAction) error
type AssertionFunc ¶
type AssertionFunc func(assertions playwrightgo.PlaywrightAssertions, locator playwrightgo.Locator, action *ExecutorAction, page ...*playwrightgo.Page) error
type Executor ¶
type Executor struct {
Name string `json:"name,omitempty" yaml:"name,omitempty"`
Description string `json:"description,omitempty" yaml:"description,omitempty"`
URL string `json:"url" yaml:"url"`
Browser string `json:"browser" yaml:"browser"`
Device string `json:"device" yaml:"device"`
Actions []ExecutorAction `json:"actions" yaml:"actions"`
Headless bool `json:"headless" yaml:"headless"`
}
func (Executor) ZeroValueResult ¶
func (Executor) ZeroValueResult() interface{}
ZeroValueResult return an empty implementation of this executor result
type ExecutorAction ¶
type ExecutorAction struct {
Action string `json:"action"` // The action to perform, must be a valid/supported action
Selector string `json:"selector" yaml:"selector"` // DOM selector or expression
Content string `json:"content,omitempty" yaml:"content"` // Content for actions that require it
Options any `json:"options,omitempty" yaml:"options"` // Options applicable to the given action
}
func NewExecutorAction ¶
func NewExecutorAction(act *basi.Action) *ExecutorAction
func (ExecutorAction) String ¶
func (a ExecutorAction) String() string
Click to show internal directories.
Click to hide internal directories.