daily pastebin goal
32%
SHARE
TWEET

Untitled

a guest Dec 13th, 2018 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. let itWorked = true;
  2.     let attempts = 0;
  3.     do {
  4.       itWorked = true;
  5.       try {
  6.         await this.linkThatIsCausingProblem.click();
  7.         await this.driver.wait(until.elementIsVisible(this.elementThatWouldIndicateTheClickWorked), this.MAX_WAIT_FOR_PAGE_TO_UPDATE);
  8.       } catch (error) {
  9.         itWorked = false;
  10.         await this.driver.sleep(1000);
  11.         attempts ++;
  12.       }
  13.     } while (itWorked === false && attempts < 5);
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top