Skip to content

Hover Steps

Beginners: start with Locators if you still need the UI-element workflow first. This page is the exact hover-step reference.

Source: src/tests/steps/actions/hover.step.ts.

See shared placeholder rules in Step Parameter Conventions.

Prefer installing published steps with npx appraisejs@latest add step ... instead of adding the package to your project with npm install.

Use hover when the UI reveals state only after pointer movement, such as menus, tooltips, or nested controls.

the user hovers the cursor over the {string} element

Terminal window
npx appraisejs@latest add step hover/hover
  • Resolves locator by name.
  • Runs Playwright hover() on the target element.
ParameterRepresentsExpected data
{string}Target locator nameExisting locator key (for example menuTrigger).
When the user hovers the cursor over the "menuTrigger" element
  • Step fails if locator is missing.
  • Step fails if hover action cannot be completed.