chore: Assert using cy.window property so that assertion retries to reduce flaky in test (#28912)

* Assert using cy.window property so that it retries

* empty commit
This commit is contained in:
Jennifer Shehane
2024-02-09 15:49:35 -05:00
committed by GitHub
parent 6cad8ac159
commit d046bfc264

View File

@@ -187,9 +187,9 @@ describe('driver/src/cy/timers', () => {
// now go ahead and run all the queued timers
return cy.pauseTimers(false)
})
.then(() => {
expect(win.bar).to.eq('bar')
cy.window().its('bar').should('eq', 'bar')
.and(() => {
// requestAnimationFrame should have passed through
// its high res timestamp from performance.now()
expect(rafStub).to.be.calledWithMatch(Number)