Skip to content

v1.31.0

Compare
Choose a tag to compare
@dgozman dgozman released this 28 Feb 23:15
80fa0c6

New APIs

New assertion assertThat(locator).isInViewport() ensures that locator points to an element that intersects viewport, according to the intersection observer API.

Locator locator = page.getByRole(AriaRole.BUTTON);

// Make sure at least some part of element intersects viewport.
assertThat(locator).isInViewport();

// Make sure element is fully outside of viewport.
assertThat(locator).not().isInViewport();

// Make sure that at least half of the element intersects viewport.
assertThat(locator).isInViewport(new LocatorAssertions.IsInViewportOptions().setRatio(0.5));

Miscellaneous

  • DOM snapshots in trace viewer can be now opened in a separate window.
  • New option setMaxRedirects for method Route.fetch.
  • Official docker images now include Node 18 instead of Node 16.

Browser Versions

  • Chromium 111.0.5563.19
  • Mozilla Firefox 109.0
  • WebKit 16.4

This version was also tested against the following stable channels:

  • Google Chrome 110
  • Microsoft Edge 110