Repository navigation
0.19.0
What's Changed
Details
New capture() API
Supports the new capture() API for capturing screen reader output produced by arbitrary actions.
This enables seemless integration with Playwright, allowing Guidepup to associate spoken phrases and item text with interactions performed using Playwright APIs. The action’s result is returned alongside the captured screen reader output.
Example:
const capture = await screenReader.capture(() =>
page.getByRole("button", { name: "Add to cart" }).click(),
);
expect(capture.spokenPhrase).toContain("Added to cart");This paves the way for auto-instrumentation of Playwright tests where existing tests can be re-used to also allow assertions on screen reader output without explicit Guidepup commands.
Misc
- This change also improves some of the types for exported Playwright test instances.
- BREAKING: Minimum version of
@guidepup/guidepuppeer dependency bumped to0.33.0
Full Changelog: 0.18.0...0.19.0