Comments (5)
#75 contains a longer explanation, the solution is
cy.waitUntil(() => Cypress.$(".e2e-my-lessons-grid > *").length, { timeout: 120000, interval: 1000 })
from cypress-wait-until.
Hi @mesqueeb! In order to understand why your use of waitUntil can't work (using a Cypress assertion inside the waitUntil checker function), please take a look at #139 and #35. If they are not enough, feel free to reopen the issue 😉
Best
Stefano
from cypress-wait-until.
@mesqueeb last not least: if you only need a different timeout for cy.get(".e2e-my-lessons-grid > *").should("exist")
... You do not need this plugin! Cypress commands' timeout is customizable, take a look at cy.get
options.
Then, simply write
cy.get(".e2e-my-lessons-grid > *", {timeout: 120000}).should("exist")
from cypress-wait-until.
@NoriSte I understand. thanks for the info.
I did try this however:
cy.get(".e2e-my-lessons-grid > *", {timeout: 120000}).should("exist")
the problem is that there is no way to set the "interval" and it's literally checking almost every 10ms, really eating up the memory.
That's why I want to use your library to set an interval of around 500ms or so.
How can I use your library to wait until a Dom element exists with a long timeout and an interval of 500ms?
PS: it's not possible to re-open issues that are closed by the repo owner 😅
from cypress-wait-until.
@NoriSte Again, you're a legend!!
from cypress-wait-until.
Related Issues (20)
- Great use of wait-until if you have detached dom problems HOT 1
- Document Promise.reject() as anti-pattern HOT 3
- Timed out retrying after 4000ms: Expected to find element HOT 2
- Global timeout HOT 3
- Overwrite WaitUntil command HOT 3
- Cypress throw an error when returning `true` inside the cy.waitUntil callback HOT 4
- Example/Document Request: How to catch 'errorMsg' if cy.waitUntil() exceeds 'timeout'? HOT 1
- How to write test code about progess bar by waituntil HOT 3
- Wait for DOM change in order to assert completion of a job HOT 3
- Element is never found when timeout options are overrided HOT 5
- Update plugin to be compatible with Cypress 10 HOT 4
- feature request: use config file to set default timeout HOT 2
- Question: can I waitUntil multiple elements appear? HOT 2
- Cypress configuration error HOT 3
- Using cy.reload() - Failed because you are mixing up async and sync code. HOT 5
- Not working on the latest cypress version HOT 5
- Timeout can take longer than defined HOT 6
- allow node 16 HOT 5
- Is version 2.0.1 compatible with cypress 10? HOT 3
- Problem with TypeScript signature HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cypress-wait-until.