Skip to content
masterclass Buddy

Playwright · Matcher

toContainClass

Playwright assertions check values and web conditions. Web-specific assertions retry until the condition passes or the 5-second assertion timeout is reached.

Last updated

Syntax

expect(value).matcher(expected)

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

Subscribe
  • expect.poll
  • expect.toPass
  • toBeVisible
  • toHaveText
  • toHaveURL
  • testConfig.expect

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