Repository navigation
Playwright Integration #2246
KonnorRogers
started this conversation in
General
Replies: 1 comment
|
I also started adding E2E tests to this open source project eclipse-docks which heavily relies on Lit/WebAwesome: It seems playwright can nicely interact with the (shadow) DOM. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
I don't know if this discussion will lead to anything, but my general thought currently as im working through adding E2E tests to Web Awesome and documenting selectors that are "broken" or require workarounds.
Waiting for elements to load
Currently, I add a
waitForComponentsToLoad()script, which waits for all components to be:defined+updateCompleteAnd then in my tests:
Specific Elements
<wa-input>-> seems to work as expected withawait page.getByRole("textbox", { name: /Name/i }).fill("Konnor")<wa-checkbox>-> can properly locate withpage.getByRole("checkbox", { name: /I agree/i }), but is not able to.checked()or.click(), instead, need to do:await page.getByRole("checkbox", { name: /I agree/i }).dispatchEvent("click")(Will be adding more as more things get tested and quirks are discovered)
All reactions