github.com/MontFerret/ferret@v0.18.0/e2e/tests/dynamic/element/iframes/wait_class.fql (about) 1 LET url = @lab.cdn.dynamic + "?redirect=/iframe&src=/events" 2 LET page = DOCUMENT(url, { driver: 'cdp' }) 3 LET doc = page.frames[1] 4 5 WAIT_ELEMENT(doc, "#page-events") 6 7 // with fixed timeout 8 LET b1 = ELEMENT(doc, "#wait-class-btn") 9 LET c1 = ELEMENT(doc, "#wait-class-content") 10 11 WAIT(2000) 12 CLICK(b1) 13 14 WAIT_CLASS(c1, "alert-success") 15 16 // with random timeout 17 LET b2 = ELEMENT(doc, "#wait-class-random-btn") 18 LET c2 = ELEMENT(doc, "#wait-class-random-content") 19 20 CLICK(b2) 21 WAIT_CLASS(c2, "alert-success", 10000) 22 23 RETURN ""