Example usage for org.openqa.selenium.support.ui ExpectedConditions visibilityOf

List of usage examples for org.openqa.selenium.support.ui ExpectedConditions visibilityOf

Introduction

In this page you can find the example usage for org.openqa.selenium.support.ui ExpectedConditions visibilityOf.

Prototype

public static ExpectedCondition<WebElement> visibilityOf(final WebElement element) 

Source Link

Document

An expectation for checking that an element, known to be present on the DOM of a page, is visible.

Usage

From source file:org.eclipse.che.selenium.pageobject.GoogleLogin.java

License:Open Source License

public void typeLogin(String login) {
    new WebDriverWait(seleniumWebDriver, 10).until(ExpectedConditions.visibilityOf(emailInput)).sendKeys(login);
    emailInput.sendKeys(Keys.ENTER.toString());
}

From source file:org.eclipse.che.selenium.pageobject.GoogleLogin.java

License:Open Source License

/** type into password field on Google authorization page user - defined password */
public void typePasswordDefinedByUser(String password) {
    new WebDriverWait(seleniumWebDriver, 10).until(ExpectedConditions.visibilityOf(passwordInput))
            .sendKeys(password);//from  ww w  . j  av a2  s  .  c om
    passwordInput.sendKeys(Keys.ENTER.toString());
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/** wait while main widget will appear */
public void waitMainForm() {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(mainForm));
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/**
 * type user uri into URL: field//  www.ja  v  a 2  s. c  o  m
 *
 * @param uri
 */
public void typeURi(String uri) {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(urlField)).clear();
    loader.waitOnClosed();
    urlField.sendKeys(uri);
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/**
 * type a name of the project//ww w .  jav  a 2 s.  c  om
 *
 * @param nameOfProject
 */
public void typeProjectName(String nameOfProject) {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(nameField));
    nameField.clear();
    loader.waitOnClosed();
    nameField.sendKeys(nameOfProject);
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/** click on 'Import' button and wait what the 'Import project' window was closed */
public void clickImportBtn() {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(importBtn)).click();
    waitMainFormIsClosed();//from w w  w .  j  av  a  2 s .  c o  m
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/** click on 'Import' button */
public void clickImportBtnWithoutWait() {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(importBtn)).click();
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/** click on Git field */
public void selectGitSourceItem() {
    new WebDriverWait(seleniumWebDriver, 10).until(ExpectedConditions.visibilityOf(gitSourceItem));
    loader.waitOnClosed();//  w  w  w .j  a v a 2 s.  com
    gitSourceItem.click();
    loader.waitOnClosed();
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/** click on GitHub field */
public void selectGitHubSourceItem() {
    new WebDriverWait(seleniumWebDriver, REDRAW_UI_ELEMENTS_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(gitHubSourceItem)).click();
}

From source file:org.eclipse.che.selenium.pageobject.ImportProjectFromLocation.java

License:Open Source License

/**
 * select specified item into github account dropdown list
 *
 * @param item item for selection//from   w ww  .j a va 2  s . c om
 */
public void selectItemInAccountList(String item) {
    new WebDriverWait(seleniumWebDriver, LOAD_PAGE_TIMEOUT_SEC)
            .until(ExpectedConditions.visibilityOf(githubAccountList));
    new Select(githubAccountList).selectByValue(item);
}