Features you might have missed
Use these focused capabilities when exact text, stable locators, or report tooling need more than the basic path.
Smart Locators
- What it does
- Finds likely input and clickable controls when a stable locator is not yet known.
- Why use it
- Move quickly during throwaway exploration.
- Configure
- No setup is required beyond a web driver session.
- Use it
- Use a Smart Locator while exploring, then replace it with a stable locator in repository code.
ARIA role locators
- What it does
- Builds locators from an accessible role and normalized visible text.
- Why use it
- Express the user-facing control semantics in readable test code.
- Configure
- No separate configuration is needed.
- Use it
- Build the role locator through SHAFT.GUI.Locator and use it in the page object.
Localization assertions
- What it does
- Validates text language and direction through ValidationEnums.TextLanguage and TextDirection.
- Why use it
- Check localized content beyond an exact string comparison.
- Configure
- Choose the expected language or direction in a native validation builder.
- Use it
- Assert or verify the element text, then inspect the validation evidence.
Allure 3 compatibility mode
- What it does
- Generates managed Allure 3 reports while retaining explicit compatibility behavior for Allure 2.
- Why use it
- Move report tooling forward without hiding which CLI mode is active.
- Configure
- Keep allure.forceConfiguredCliVersion=true for managed Allure 3 or set false for PATH-first compatibility behavior.
- Use it
- Generate the report and verify its selected CLI mode in the run output.
Build an accessible role locator for durable page-object code:
By login = SHAFT.GUI.Locator.hasRole(Role.BUTTON).hasNormalizedText("Log in").build();