Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add waitForElement support #3

Open
patrickhulce opened this issue Jun 29, 2018 · 0 comments

Comments

Projects
None yet
1 participant
@patrickhulce
Copy link
Collaborator

commented Jun 29, 2018

Puppeteer has its own set of waitForSelector methods so this requires some thought. My inclination is to just better document how to do the same thing with puppeteer than match exact API

Proposals

// Use puppeteer but expose dom-testing-library globally
await state.page.waitFor(() => __dom_testing_library__.queryByTestId('foo'), {polling: 'mutation'})

// Tell people to stick with `wait`
const {queries, wait} = require('pptr-testing-library')
await wait(() => queries.getByTestId($document, 'foo'))

@patrickhulce patrickhulce added the parity label Jul 12, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.