-
Notifications
You must be signed in to change notification settings - Fork 159
Closed
Description
cypress-testing-libraryversion: 2.0.0nodeversion: 8.4.0npmversion: 5.3.0
Problem description:
Currently, the timeout for queries is hard-coded to 3000:
https://github.com/kentcdodds/cypress-testing-library/blob/master/src/index.js#L11
When I visit my app, it shows a loading indicator, which takes more than 3 seconds. I can add a cy.wait to make things work, but if the website gets faster, that wait just slows everything down. So I'd like to be able to configure the timeout as an option to the query functions.
Suggested solution:
Destructure the last option in the command function {timeout, ...args} and use it in waitForElement, like timeout: timeout || 3000.
I'll create a PR this weekend.
tmarnet
Metadata
Metadata
Assignees
Labels
No labels