-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Closed
Description
Context:
Playwright Version: 0.15.0
Operating System: Ubuntu 18.04.4
Code Snippet
(async () => {
// below lines used to create a profile with name 'add_profile_test'
await page.click('#add-profile-btn');
await page.fill('#profile input[type=text]','add_profile_test');
await page.click('#dialog-btn');
// after create it, then select it
await page.waitForSelector('text=add_profile_test', {waitFor: 'visible',});
await page.click('text=add_profile_test');
})
Describe the bug
when try to click the element ('text=add_profile_test'), it reports 'Node is either not visible or not an HTMLElement'.
but if I add one line page.waitFor(1000)
before await page.click('text=add_profile_test')
, then it can work, I don't understand why. Shouldn't waitForSelector and waitFor function work for this?
Metadata
Metadata
Assignees
Labels
No labels