Examples of sendKeys()


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

        showAnnotationByText(searchText);
        waitUntilElementIsVisible(By.xpath("//div[@class='annotationText']/p"));
        String annotationContent = getDriver().findElement(By.xpath(
            "//*[@class='annotation-bubble']//div[@class='annotationText']/p")).getText();
        WebElement body = getDriver().findElement(By.id("body"));
        body.sendKeys(Keys.ESCAPE);
        waitUntilElementDisappears(By.className("annotation-box-view"));
        return annotationContent;
    }
}
View Full Code Here

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

    public void filterColumn(String inputId, String filterValue)
    {
        // Reset the livetable status since the filtering will cause a reload
        clearStatus();
        WebElement element = getDriver().findElement(By.id(inputId));
        element.sendKeys(filterValue);
        waitUntilReady();
    }

    /** Drop the element that signals that the livetable finished loading. */
    private void clearStatus()
View Full Code Here

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

    }

    public void simulateCTRL_M()
    {
        WebElement body = getDriver().findElement(By.id("body"));
        body.sendKeys(Keys.CONTROL, "m");
    }
}
View Full Code Here

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


    private void changeFieldValue(String fieldId, String value) {
        final WebElement field = portal.findElement(By.id(fieldId));
        field.clear();
        field.sendKeys(value);
    }

    private void sleep(long milis) {
        try {
            Thread.sleep(milis);
View Full Code Here

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

        getDriver().findElement(By.name("name")).clear();
        getDriver().findElement(By.name("name")).sendKeys("File");
        // getDriver().findElement(By.name("file")).clear();
        final WebElement fileinput = getDriver().findElement(By.name("file"));
        fileinput.sendKeys(new File("pom.xml").getAbsolutePath());
        getDriver().findElement(By.cssSelector("button.btn.btn-primary")).click();
        assertTrue(waitForElement(By.cssSelector("div.alert-success")));
    }

    public void testLogout() throws InterruptedException {
View Full Code Here

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

      driverWithReporting.register(loggingListener);
    }

    driverWithReporting.get("http://www.google.com");
    WebElement element = driverWithReporting.findElement(By.name("q"));
    element.sendKeys("Mifos");
    element.submit();
   
        (new WebDriverWait(driverWithReporting, 10))
          .until(ExpectedConditions.presenceOfElementLocated(By.id("bfoot")));
       
View Full Code Here

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

            consumersWindows.put(i, newConsumer);

            String message = "Test string " + (i + 1);

            input.sendKeys(message);

            webDriver.findElement(SUBMIT).click();

            assertTrue("The input should be empty after submiting!", input.getText().equals(""));
View Full Code Here

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

    public void testRendering() {
        browser.get(contextPath + "NestedRepeatTest.jsf");

        for (int i = 0; i < 3; i++) {
            WebElement input = browser.findElement(By.id("form:outer:" + i + ":inner:0:input"));
            input.sendKeys(Integer.toString(i));
        }

        WebElement ajax = browser.findElement(By.id("form:ajax"));
        guardAjax(ajax).click();
View Full Code Here

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

    @Test
    public void listener_with_parameter() throws InterruptedException {
        // given
        browser.get(contextPath.toExternalForm());
        WebElement cell = browser.findElement(By.id("myForm:input"));
        cell.sendKeys("123");
        Graphene.guardAjax(cell).sendKeys(Keys.TAB);
        cell = browser.findElement(By.id("myForm:input"));
        Assert.assertEquals("4", cell.getAttribute("value"));
    }
View Full Code Here

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

    public void input_single() {
        browser.get(contextPath.toExternalForm());
        WebElement input;
        input = browser.findElement(By.id("myForm:input"));
        Assert.assertEquals("0", input.getAttribute("value"));
        input.sendKeys("123");
        WebElement submit = browser.findElement(By.id("myForm:submit"));
        Graphene.guardAjax(submit).click();
        Assert.assertEquals("0123", input.getAttribute("value"));
        WebElement clear = browser.findElement(By.id("myForm:clear"));
        Graphene.guardAjax(clear).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.