Uploaded February 2024 | Updated September 2026, 1 week ago
This is part 3 of refactoring Cypress tests. In this video, I show writing a recursive test that checks a paginated list shown by the app to ensure the deleted user name does not appear in the list. But there are a couple of pitfalls in the application that make writing such tests hard(er). I summarized these tough cases and how to solve them in my blog post "Solve Tough Pagination Cases Using Cypress" glebbahmutov.com/blog/solve-tough-pagination-cases-using-cypress Find the full source code in the repo github.com/bahmutov/basta-spring-2024-cypress-and-playwright
This is part 3 of refactoring Cypress tests. In this video, I show writing a recursive test that checks a paginated list shown by the app to ensure the deleted user name does not appear in the list. But there are a couple of pitfalls in the application that make writing such tests hard(er). I summarized these tough cases and how to solve them in my blog post "Solve Tough Pagination Cases Using Cypress" glebbahmutov.com/blog/solve-tough-pagination-cases-using-cypress Find the full source code in the repo github.com/bahmutov/basta-spring-2024-cypress-and-playwright



![Case-Insensitive Query With Retries
This video shows how you can use Cypress.$ jQuery method to select elements without matching the attribute casing. While cy.get does not allow you to pass i suffix to mark the CSS selector case-insensitive (see bug https://github.com/cypress-io/cypress/issues/25304) you can work around it by using Cypress.$(... i) or even retry it by doing cy.wrap(Cypress).invoke($, ...i)
// static page, lets find all buttons with class btn-primary or bTn-PrImArY
cy.wrap(Cypress.$(button[class=btn-primary i])).should(
have.length,
2,
)
// dynamic page, retry the query
cy.wrap(Cypress)
.invoke($, button[class=btn-primary i])
.should(have.length, 2)
Find the full recipe at https://glebbahmutov.com/cypress-examples Case-Insensitive Query With Retries](https://i.ytimg.com/vi/XQ6GQSmF5_I/mqdefault.jpg)






