Package org.openqa.selenium

Examples of org.openqa.selenium.ElementNotVisibleException


        return isDisplayed();
      }
    });

    if (displayed == null || !displayed) {
      throw new ElementNotVisibleException(message);
    }
  }
View Full Code Here


        performAction.moveToElement(plotLine).moveToElement(elementToHoverOver, xHoverPoint, yHoverPoint).perform();
    }

    private PlotPoint getPlotPoint(int point) throws ElementNotVisibleException {
        if (point < 0) {
            throw new ElementNotVisibleException("Plot point ${point} not found");
        }
        return getPlotPoints().get(point);
    }
View Full Code Here

      throw new StaleElementReferenceException(
          String.format("You may not %s this element. It looks as if the reference is stale. " +
                        "Did you navigate away from the page with this element on?", message));

    case 11:
      throw new ElementNotVisibleException(
          String.format("You may not %s an element that is not displayed", message));
     
    case 12:
      throw new UnsupportedOperationException(
              String.format("You may not %s an element that is not enabled", message));
View Full Code Here

  public void click() {
    assertElementNotStale();

    if (!isDisplayed())
      throw new ElementNotVisibleException("You may only click visible elements");

    try {
      if (parent.isJavascriptEnabled()) {
        if (!(element instanceof HtmlInput)) {
          element.focus();
View Full Code Here

    assertElementNotStale();

    String originalValue = getValue();

    if (!isDisplayed())
      throw new ElementNotVisibleException("You may only sendKeys to visible elements");

    StringBuilder builder = new StringBuilder();
    for (CharSequence seq : value) {
      builder.append(seq);
    }
View Full Code Here

  public boolean toggle() {
    assertElementNotStale();

    if (!isDisplayed())
      throw new ElementNotVisibleException("You may only toggle visible elements");


    try {
      if (element instanceof HtmlCheckBoxInput) {
        element.click();
View Full Code Here

  public void setSelected() {
    assertElementNotStale();

    if (!isDisplayed())
      throw new ElementNotVisibleException("You may only select visible elements");


    String disabledValue = element.getAttribute("disabled");
    if (disabledValue.length() > 0) {
      throw new UnsupportedOperationException("You may not select a disabled element");
View Full Code Here

    }

    @Step
    public void data_driven_test_step_that_breaks() {
        if (Integer.parseInt(age) > 35) {
            throw new ElementNotVisibleException("A webdriver issue");
        }
    }
View Full Code Here

        return webDriver;
    }

    @Override
    public WebElement activeElement() {
        throw new ElementNotVisibleException("No active element found (a previous step has failed)");
    }
View Full Code Here

    }

    @Step
    public void data_driven_test_step_that_breaks() {
        if (Integer.parseInt(age) > 35) {
            throw new ElementNotVisibleException("A webdriver issue");
        }
    }
View Full Code Here

TOP

Related Classes of org.openqa.selenium.ElementNotVisibleException

Copyright © 2018 www.massapicom. 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.