MCPcopy Index your code
hub / github.com/microsoft/playwright-python / test_locators_wait_for

Function test_locators_wait_for

tests/async/test_locators.py:500–506  ·  view source on GitHub ↗
(page: Page)

Source from the content-addressed store, hash-verified

498
499
500async def test_locators_wait_for(page: Page) -> None:
501 await page.set_content("<div></div>")
502 locator = page.locator("div")
503 task = locator.wait_for()
504 await page.eval_on_selector("div", "div => div.innerHTML = '<span>target</span>'")
505 await task
506 assert await locator.text_content() == "target"
507
508
509async def test_should_wait_for_hidden(page: Page) -> None:

Callers

nothing calls this directly

Calls 5

set_contentMethod · 0.45
locatorMethod · 0.45
wait_forMethod · 0.45
eval_on_selectorMethod · 0.45
text_contentMethod · 0.45

Tested by

no test coverage detected