use of org.openqa.selenium.firefox.FirefoxDriver in project java.webdriver by sayems.
the class isDisplayed method main.
public static void main(String[] args) {
WebDriver driver = new FirefoxDriver();
driver.get("http://www.google.com");
WebElement searchButton = driver.findElement(By.name("btnK"));
System.out.println(searchButton.isDisplayed());
}
use of org.openqa.selenium.firefox.FirefoxDriver in project java.webdriver by sayems.
the class isEnabled method main.
public static void main(String[] args) {
WebDriver driver = new FirefoxDriver();
driver.get("http://www.google.com");
WebElement searchButton = driver.findElement(By.name("btnK"));
System.out.println(searchButton.isEnabled());
}
use of org.openqa.selenium.firefox.FirefoxDriver in project java.webdriver by sayems.
the class ImplicitWaitTime method main.
public static void main(String... args) {
WebDriver driver = new FirefoxDriver();
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.get("www.google.com");
}
use of org.openqa.selenium.firefox.FirefoxDriver in project java.webdriver by sayems.
the class GetAttributes method main.
public static void main(String[] args) {
WebDriver driver = new FirefoxDriver();
driver.get("http://www.google.com");
WebElement searchButton = driver.findElement(By.name("btnK"));
System.out.println("Name of the button is: " + searchButton.getAttribute("name"));
System.out.println("Id of the button is: " + searchButton.getAttribute("id"));
System.out.println("Class of the button is: " + searchButton.getAttribute("class"));
System.out.println("Label of the button is: " + searchButton.getAttribute("aria- label"));
}
use of org.openqa.selenium.firefox.FirefoxDriver in project java.webdriver by sayems.
the class GetCSSValue method main.
public static void main(String[] args) {
WebDriver driver = new FirefoxDriver();
driver.get("http://www.google.com");
WebElement searchButton = driver.findElement(By.name("btnK"));
System.out.println(searchButton.getCssValue("font-family"));
}
Aggregations