How to add delay in retry logic when commands assertion fails in cypress

Viewed 117
cy.get('a').pipe(click).should($el => {
    expect($el.parents('body')).to.have.class('da-popup-open')})

Above logic keeps clicking on link until body element updated with class 'da-popup-open'. I want to wait for it for some time then retry for the click.

Thanks!

0 Answers
Related