-
Notifications
You must be signed in to change notification settings - Fork 5k
Closed
Description
Originally described in MarketSquare/robotframework-browser#1519
Hi, I am trying to assert visibility of some React elements using the _react selector strategy introduced in 1.14. I am using Playwright for Python to test the, unminified, React app from https://github.com/alexanmtz/material-sense running locally.
from playwright.sync_api import sync_playwright
with sync_playwright() as p:
browser = p.chromium.launch()
page = browser.new_page()
page.goto("http://localhost:8000")
print(page.title())
visible = page.is_visible('_react=Tab[label = "Home"]') # this element can not be found
assert visible
browser.close()The assertion fails because the element is deemed not visible, but I can't seem to be find why. For some other elements of the app, such as _react=Topbar, it works as expected. I just can't seem to figure out what I might be doing wrong and I'd appreciate any help.
Metadata
Metadata
Assignees
Labels
No labels
