Example usage for org.openqa.selenium By linkText

List of usage examples for org.openqa.selenium By linkText

Introduction

In this page you can find the example usage for org.openqa.selenium By linkText.

Prototype

public static By linkText(String linkText) 

Source Link

Usage

From source file:com.hotwire.selenium.bex.BexAbstractPage.java

License:Open Source License

protected void clickOnLink(String linkText, int waitTimeout) {
    new WebDriverWait(getWebDriver(), waitTimeout)
            .until(ExpectedConditions.visibilityOfElementLocated(By.linkText(linkText))).click();
}

From source file:com.hotwire.selenium.desktop.helpCenter.Salesforce.SFArticlePage.java

License:Open Source License

public boolean getEmail() {
    try {// w w  w  .  j av  a 2s.c o m
        getWebDriver().findElement(By.linkText("Send us an email"));
        return true;
    } catch (NoSuchElementException e) {
        return false; //To change body of catch statement use File | Settings | File Templates.
    }
}

From source file:com.hotwire.selenium.desktop.helpCenter.Salesforce.SFIntlIndexPage.java

License:Open Source License

public SFIntlIndexPage(WebDriver webDriver) {
    super(webDriver, By.linkText("Help Centre"));
}

From source file:com.hotwire.selenium.desktop.us.search.AirSearchFragment.java

License:Open Source License

private int getSeeAllCitiesCount() {
    ArrayList<String> handles = new ArrayList<>(getWebDriver().getWindowHandles());
    getWebDriver().switchTo().window(handles.get(1));

    new WebDriverWait(getWebDriver(), DEFAULT_WAIT)
            .until(PageObjectUtils.webElementVisibleTestFunction(By.cssSelector("div#tileName-A1"), true));

    List<WebElement> links = getWebDriver().findElements(By.linkText("international cities"));
    return links.size();
}

From source file:com.hotwire.selenium.tools.c3.customer.hotDollars.C3CustomerHotDollarsForm.java

License:Open Source License

public void viewCaseNotes() {
    final List<WebElement> links = findMany(By.linkText("Click to view"));
    links.get(links.size() - 1).click();
}

From source file:com.hotwire.selenium.tools.c3.customer.itineraryDetails.C3ItineraryDetailsPage.java

License:Open Source License

public boolean isLPGLinkDisplayed() {
    return isElementDisplayed(By.linkText("Low Price Guarantee Claim"));
}

From source file:com.hotwire.selenium.tools.c3.hotel.C3HotelHomePage.java

License:Open Source License

public String getOverchargeDetailsURL() {
    String onclick = getWebDriver().findElement(By.linkText("Overcharge Details")).getAttribute("onclick");
    return onclick.replaceFirst("^.*\\('", "").replaceFirst("'.*$", "");
}

From source file:com.hotwire.test.steps.application.ApplicationModelTemplate.java

License:Open Source License

@Override
public void clickOnLink(String linkText) {
    getWebdriverInstance().findElement(By.linkText(linkText)).click();
}

From source file:com.hotwire.test.steps.bex.BexAbstractModel.java

License:Open Source License

public void clickOnLink(String linkText) {
    getWebdriverInstance().findElement(By.linkText(linkText)).click();
}

From source file:com.hotwire.test.steps.helpcenter.SalesforceHelpCenterModel.java

License:Open Source License

@Override
public void clickSendUsEmailLink() {
    getWebdriverInstance().findElement(By.linkText("Send us an email")).click();
}