2 Şubat 2017 Perşembe

selenium xpath example

driver.findElement(By.xpath("/html/body/div/input[1]")).sendKeys("123");

driver.findElement(By.xpath("//input[1]")).click();

driver.findElement(By.xpath("(//input[1])[4])")).click();

driver.findElement(By.xpath("//tag[@AN='AV']")).sendKeys("123");

driver.findElement(By.xpath("//tag[text()='AV']")).sendKeys("123");

driver.findElement(By.xpath("//tag[@AN='AV' and @AN='AV']")).click();




driver.findElement(By.xpath("//tag[contains(text(),'usrn')]").getText();

driver.findElement(By.xpath("//tag[contains(@AN,'usrn')]").getText();

driver.findElement(By.xpath("//tag[starts-with(text(),'usrn')]").getText();
driver.findElement(By.xpath("//tag[starts-with(@AN,'usrn')]").getText();