Skip to content
masterclass Buddy

Playwright · Function

expect.soft

Playwright's expect function checks values and web page state. Web assertions retry until they pass or the five-second default timeout is reached.

Last updated

Syntax

expect(value).matcher(expected)
await expect(locator).webMatcher(expected)
expect.soft(value).matcher(expected)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • expect.configure
  • expect.poll
  • expect.toPass
  • expect.extend
  • expect.soft

Source: Assertions | Playwright. Checked 2026-11-03.