Package org.openqa.selenium

Examples of org.openqa.selenium.WebElement.clear()


    WebElement fieldValueInput =
            driver.findElements(
                    By.xpath(
                            "//legend[contains(text(),'Form Field Input Values')]/following-sibling::table//input[@type='text']"))
                    .get(0);
    fieldValueInput.clear();
    fieldValueInput.sendKeys(" ");

    WebElement assertionsLink = driver.findElements(By.linkText("Assertions")).get(0);
    followLink(assertionsLink);
View Full Code Here


    WebElement newConditionInput =
            driver.findElements(
                    By.xpath(
                            "//legend[contains(text(),'Invariants')]/following-sibling::table//input[@type='text']"))
                    .get(0);
    newConditionInput.clear();
    newConditionInput.sendKeys("crawljax");

    List<WebElement> saveConfigurationLink =
            driver.findElements(By.linkText("Save Configuration"));
    followLink(saveConfigurationLink.get(0));
View Full Code Here

    WebElement copyConfigurationLink = driver.findElements(By.linkText("New Copy")).get(0);
    followLink(copyConfigurationLink);

    WebElement nameInput = driver.findElement(By.xpath(
            "//label[contains(text(),'Name:')]/following-sibling::div/input"));
    nameInput.clear();
    nameInput.sendKeys("copy");

    WebElement saveConfigurationLink =
            driver.findElements(By.linkText("Save Configuration")).get(0);
    followLink(saveConfigurationLink);
View Full Code Here

  @Override
  public boolean input(Identification identification, String text) {
    try {
      WebElement field = browser.findElement(identification.getWebDriverBy());
      if (field != null) {
        field.clear();
        field.sendKeys(text);

        return true;
      }
      return false;
View Full Code Here

  @Test
  public void showBrowserCheckPage() throws InterruptedException {

    WebElement locationBox = querySelector("#location").get(0);
    locationBox.clear();
    locationBox
    .sendKeys("http://localhost:8080/htmlhifiveWeb/coverage/webdriver/sandboxInternal/coverage/");
    WebElement openInFrame = querySelector("[title='open URL in the iframe below [Enter]']").get(0);
    openInFrame.click();
    Thread.sleep(100);
View Full Code Here

    } catch(Exception e){
      return;
    }
    // ページを開く処理をBeforeClassに記述すると、コンストラクタの前に実行されてしまうため、コンストラクタで実行している。
    WebElement locationBox = querySelector("#location").get(0);
    locationBox.clear();
    locationBox.sendKeys(BLOCK_SAMPLE_PAGE);
    WebElement openInWindow = querySelector("[title='open URL in the iframe below [Enter]']").get(0);
    openInWindow.click();
    Thread.sleep(1000);
  }
View Full Code Here

  }

  @Test
  public void openQUnit() throws InterruptedException{
    WebElement locationBox = querySelector("#location").get(0);
    locationBox.clear();
    locationBox.sendKeys(QUNIT_PAGE);
    WebElement openInWindow = querySelector("[title='open URL in the iframe below [Enter]']").get(0);
    openInWindow.click();
    Thread.sleep(1000);
  }
View Full Code Here

  }
  @Test
  public void openQUnit() throws InterruptedException{

    WebElement locationBox = querySelector("#location").get(0);
    locationBox.clear();
    locationBox.sendKeys(QUNIT_PAGE);
    WebElement openInWindow = querySelector("[title='open URL in the iframe below [Enter]']").get(0);
    openInWindow.click();
    Thread.sleep(1000);
  }
View Full Code Here

    {
        WebDriver driver = getDriver();
        // Test Begins
        // Making sure the textBox is empty so we always start at the same date
        WebElement element = findDomElement(By.cssSelector(DATE_INPUT_BOX_SEL));
        element.clear();
        element.sendKeys(TEST_DATE_TO_USE);

        // Grabbing the Date Icon and click on it to open the calendar
        element = findDomElement(By.cssSelector(DATE_ICON_SEL));
        element.click();
View Full Code Here

    private String homeEndButtonHelper(String initDate, Keys buttonToPress)
    {
        // Getting the input box, making sure it is clear, and sending in the the starting date
        WebElement element = findDomElement(By.cssSelector(DATE_INPUT_BOX_SEL));
        element.clear();
        element.sendKeys(initDate);

        // Opening the calendar icon to grab the date we are looking for
        element = findDomElement(By.cssSelector(DATE_ICON_SEL));
        element.click();
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.