-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathwbd1.java
More file actions
22 lines (18 loc) · 893 Bytes
/
wbd1.java
File metadata and controls
22 lines (18 loc) · 893 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import java.util.concurrent.TimeUnit;
import org.openqa.selenium.By;
import org.openqa.selenium.chrome.ChromeDriver;
public class wbd1 {
public static void main(String[] args) {
// TODO Auto-generated method stub
System.setProperty("webdriver.chrome.driver","chromedriver.exe");
ChromeDriver driver = new ChromeDriver();
driver.manage().window().maximize();
driver.manage().timeouts().implicitlyWait(30,TimeUnit.SECONDS);
driver.get("http://www.facebook.com");
driver.findElement(By.id("u_0_j")).sendKeys("Testing");
driver.findElement(By.id("u_0_l")).sendKeys("Selenium");
driver.findElement(By.name("reg_email__")).sendKeys("testing@gmail.com");
driver.findElement(By.name("reg_email_confirmation__")).sendKeys("testing@gmail.com");
driver.findElement(By.name("websubmit")).click();
}
}