Examples of until()


Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

    // various in page login pop-ups are detected by MP and can be submitted without clicking the link
    // that makes them visible.
    // TODO handle the other cases
    if (loginLoadedLinkText != null &&  !loginLoadedLinkText.equals(""))
    {
      wait.until(ExpectedConditions.elementToBeClickable(By.linkText(loginLoadedLinkText)));
    }

    Thread.sleep(1000);

    if (logoutLinkText != null &&  !logoutLinkText.equals(""))
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

    Thread.sleep(1000);

    if (logoutLinkText != null &&  !logoutLinkText.equals(""))
    {
      WebElement logout = wait.until(ExpectedConditions.elementToBeClickable(By.linkText(logoutLinkText)));
//      logout.click(); // clicking log out is nearly useless, MP will log back in immediately with AUTOACCEPT
    }
    else
    {
      wait.until(ExpectedConditions.presenceOfElementLocated(By.xpath("/html")));
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

      WebElement logout = wait.until(ExpectedConditions.elementToBeClickable(By.linkText(logoutLinkText)));
//      logout.click(); // clicking log out is nearly useless, MP will log back in immediately with AUTOACCEPT
    }
    else
    {
      wait.until(ExpectedConditions.presenceOfElementLocated(By.xpath("/html")));
    }
    screenshot();
  }
}
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

        WebElement notification = driver.findElements(By.id("notification")).get(0);
        return notification.getText().equals("Configuration Saved");
      }
    };
    WebDriverWait wait = new WebDriverWait(driver, 10);
    wait.until(isSaved);
  }

  private void copyConfiguration() {

    openConfiguration();
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

        WebElement notification = driver.findElements(By.id("notification")).get(0);
        return notification.getText().equals("Configuration Deleted");
      }
    };
    WebDriverWait wait = new WebDriverWait(driver, 10);
    wait.until(isDeleted);
  }

  private void runConfigurationAndViewResults() {
    openConfiguration();
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

                        "//li[contains(text(),'Crawl Execution Queue')]/following-sibling::li//span[contains(i,'running')]"));
        return running != null;
      }
    };
    WebDriverWait wait = new WebDriverWait(driver, 10);
    wait.until(isRunning);

    ExpectedCondition<Boolean> isComplete = new ExpectedCondition<Boolean>() {
      public Boolean apply(WebDriver driver) {
        WebElement success =
                driver.findElement(By
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

                        "//li[contains(text(),'Crawl Execution Queue')]/following-sibling::li//span[contains(i,'success')]"));
        return success != null;
      }
    };
    wait = new WebDriverWait(driver, 60);
    wait.until(isComplete);

    List<WebElement> crawlHistoryLink = driver.findElements(By.linkText("Crawl History"));
    followLink(crawlHistoryLink.get(0));

    WebElement crawlLink = driver.findElement(By.xpath(
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

          WebElement notification = driver.findElements(By.id("notification")).get(0);
          return notification.getText().equals("Plugin Deleted");
        }
      };
      WebDriverWait wait = new WebDriverWait(driver, 10);
      wait.until(isDeleted);
      if (!isElementPresent(driver, By.linkText("Delete"))) {
        break;
      }
      deleteLinks = driver.findElements(By.linkText("Delete"));
    }
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

        final String errorMsg = "COMPONENT markup://uitest:button_LabelRequiredTest is missing required attribute 'label'";
        openNoAura("/uitest/button_LabelRequiredTest.cmp");
        auraUITestingUtil.waitForDocumentReady();
        WebDriverWait wait = new WebDriverWait(getDriver(), timeoutInSecs);
        wait.withMessage("Required label error not displayed");
        wait.until(new ExpectedCondition<Boolean>() {
            @Override
            public Boolean apply(WebDriver d) {
                return auraUITestingUtil.getQuickFixMessage().contains(errorMsg);
            }
        });
View Full Code Here

Examples of org.openqa.selenium.support.ui.WebDriverWait.until()

        openNoAura("/auratest/testModelThatThrows.cmp");
        auraUITestingUtil.waitForDocumentReady();
        List<WebElement> errorBoxes = getDriver().findElements(By.cssSelector(".auraForcedErrorBox"));
        assertEquals("Renderer element found", 0, errorBoxes.size());
        WebDriverWait wait = new WebDriverWait(getDriver(), timeoutInSecs);
        errorBoxes = wait.until(new ExpectedCondition<List<WebElement>>() {
            @Override
            public List<WebElement> apply(WebDriver d) {
                List<WebElement> errors = getDriver().findElements(By.cssSelector(".auraErrorBox"));
                if (errors.size() > 0 && errors.get(0).isDisplayed()) {
                    return errors;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.