Package org.openqa.selenium

Examples of org.openqa.selenium.WebDriverException


                link.click();
                return null;
            }
            columnEntries.add(cell.getText());
        }
        throw new WebDriverException("Could not find message with " + column + " equal to "
                                     + value + "\nIn columbn with entries: " + columnEntries.toString());
    }
View Full Code Here


                return super.clickMessageHistory();
            }

            public InvitationActionConfirmationElement cancel()
            {
                throw new WebDriverException("Invitation cannot be canceled as an admin");
            }
View Full Code Here

            {
                notSpamButton.click();
                InvitationActionConfirmationElement confirm = new InvitationActionConfirmationElement();
                // We can't go forward unless we are on the right form.
                if (!confirm.getLabel().equalsIgnoreCase("Synopsis of findings and/or action taken")) {
                    throw new WebDriverException("Not on 'not spam' confirm page, message says: " + confirm.getLabel());
                }
                confirm.setMemo(message);
                return confirm.confirm();
            }
View Full Code Here

                return new InvitationActionConfirmationElement();
            }

            public String notSpam(String message)
            {
                throw new WebDriverException("Function only possible for admin.");
            }
View Full Code Here

    }

    public InspectInvitationsPage inspectAllInvitations()
    {
        if (!isAdmin()) {
            throw new WebDriverException("Inspection as admin impossible because user is not admin.");
        }
        this.inspectAllAsAdmin.click();
        return new InspectInvitationsPage.AsAdmin();
    }
View Full Code Here

        for(WebElement recip : getAllRecipients()) {
            if (recip.getText().contains(email)) {
                return recip.getAttribute("class").contains("valid-address");
            }
        }
        throw new WebDriverException("Recipient name (" + email + ") not found.");
    }
View Full Code Here

                                                            "doAction_" + action.toString().toLowerCase()));
        int end = messageContent.indexOf("\"", start);
        getDriver().get(messageContent.substring(start, end).replaceAll("&", "&"));
        // Make sure the right messages is displayed otherwise we can't continue.
        if(action.label != null && !confirm.getLabel().equalsIgnoreCase(action.label)) {
            throw new WebDriverException("Not on correct page, expecting memo label to say \"" + action.label + "\"");
        }
    }
View Full Code Here

            getUtil().assertOnPage(sectionPage.getURL());
            sectionPage.getForm().setFieldValue(By.name("XWiki.Registration_0_liveValidation_enabled"),
                Boolean.valueOf(useLiveValidation()).toString());
            sectionPage.clickSave();
            if (x > 2) {
                throw new WebDriverException("Unable to set useLiveValidation to " + useLiveValidation());
            }
            x++;
            registerPage.gotoPage();
        }
        // The prepareName javascript function is the cause of endless flickering
View Full Code Here

    public TableElement(WebElement table)
    {
        super();
        if (!table.getTagName().toLowerCase().equals("table")) {
            throw new WebDriverException("You can only create a TableElement using a <table> web element,"
                                         + "you passed a <" + table.getTagName() + "> element");
        }
        if (!table.findElements(By.tagName("tbody")).isEmpty()) {
            this.table = table.findElements(By.tagName("tbody")).get(0);
        } else {
View Full Code Here

    {
        for (WebElement el : valuesByElements.keySet()) {
            try {
                setFieldValue(el, valuesByElements.get(el));
            } catch (Exception e) {
                throw new WebDriverException("Couldn't set field \"" + el.getAttribute("name") + "\" to value \""
                    + valuesByElements.get(el) + "\"", e);
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.openqa.selenium.WebDriverException

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.