Method: Playwright::Page#wait_for_timeout

Defined in:
lib/playwright_api/page.rb

#wait_for_timeout(timeout) ⇒ Object

Waits for the given ‘timeout` in milliseconds.

Note that ‘page.waitForTimeout()` should only be used for debugging. Tests using the timer in production are going to be flaky. Use signals such as network events, selectors becoming visible and others instead.

“‘js // wait for 1 second await page.waitForTimeout(1000); “`

“‘python async # wait for 1 second await page.wait_for_timeout(1000) “`

“‘python sync # wait for 1 second page.wait_for_timeout(1000) “`

Shortcut for main frame’s [‘method: Frame.waitForTimeout`].

Raises:

  • (NotImplementedError)


1855
1856
1857
# File 'lib/playwright_api/page.rb', line 1855

def wait_for_timeout(timeout)
  raise NotImplementedError.new('wait_for_timeout is not implemented yet.')
end