Package org.openqa.selenium

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


                .className("first-window"));

        WebElement secondWindow = driver.findElement(By
                .className("second-window"));

        secondWindow.click();

        compareScreen("second-window-over-first");

        WebElement headerFirst = firstWindow.findElement(By
                .className("v-window-outerheader"));
View Full Code Here


        compareScreen("second-window-over-first");

        WebElement headerFirst = firstWindow.findElement(By
                .className("v-window-outerheader"));
        headerFirst.click();

        compareScreen("first-window-over-second");
    }

}
View Full Code Here

        // check additional description (second checkbox on the page)
        List<CheckBoxElement> checkBoxes = $(CheckBoxElement.class).all();
        WebElement input = checkBoxes.get(1).findElement(By.tagName("input"));
        // ensure that not checked yet
        assertEquals(null, input.getAttribute("checked"));
        input.click();
        // ensure that checked now
        assertEquals("true", input.getAttribute("checked"));

        // open alert dialog
        button = $(ButtonElement.class).first();
View Full Code Here

        TestBenchElementCommands scrollable = testBenchElement(scrollableElement);
        scrollable.scroll(1000);
        WebElement comboBox = driver.findElement(By.id(COMBOBOX_ID));
        WebElement selectButton = driver.findElement(By
                .className("v-filterselect-button"));
        selectButton.click();

        // Wait for the browser before taking a screenshot
        Thread.sleep(1000);
        compareScreen(getScreenshotBaseName());
View Full Code Here

        WebElement element = driver.findElement(By
                .className("v-window-outerheader"));

        Point location = element.getLocation();

        element.click();

        new Actions(driver).moveToElement(element).perform();
        sleep(100);
        // move pointer bit right from the caption text
        new Actions(driver).moveByOffset(50, 0).clickAndHold()
View Full Code Here

                .className("v-table-cell-wrapper"));
        WebElement rangeStart = rows.get(0);
        WebElement rangeEnd = rows.get(1);
        rangeStart.click();
        new Actions(driver).keyDown(Keys.SHIFT).perform();
        rangeEnd.click();
        new Actions(driver).keyUp(Keys.SHIFT).perform();
        driver.findElement(By.className("v-button")).click();
        WebElement extraRow = driver.findElements(
                By.className("v-table-cell-wrapper")).get(1);
        new Actions(driver).keyDown(Keys.CONTROL).click(extraRow)
View Full Code Here

    public void selectAndScrollFocusesSelectedRow() {
        openTestURL();

        WebElement selectButton = $(ButtonElement.class).caption("Select")
                .first();
        selectButton.click();
        WebElement supposedlyFocusedRow = null;
        WebElement selectedRow = null;
        WebElement focusedStyleRow = null;

        Assert.assertTrue("No row was selected",
View Full Code Here

        WebElement confirm = getDriver().findElement(
                By.id(CloseModalSubWindow.CONFIRM_BUTTON));

        // click the confirm button in the sub-window
        confirm.click();

        // assert that there's no sub-windows open
        subWindows = getDriver().findElements(
                By.id(CloseModalSubWindow.SUB_WINDOW));
        Assert.assertEquals(0, subWindows.size());
View Full Code Here

        String selectAll = Keys.chord(Keys.CONTROL, "a");
        field.sendKeys(selectAll);
        field.sendKeys(Keys.BACK_SPACE);

        button.click();

        WebElement label = getDriver().findElement(
                By.id(InputPromptGetText.LABEL2));

        Assert.assertEquals("Your input was:", label.getText().trim());
View Full Code Here

        List<WebElement> rows = treeTable.findElement(
                By.className("v-table-body")).findElements(By.tagName("tr"));

        WebElement treeSpacer = rows.get(0).findElement(
                By.className("v-treetable-treespacer"));
        treeSpacer.click();

        sleep(100);

        rows = treeTable.findElement(By.className("v-table-body"))
                .findElements(By.tagName("tr"));
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.