Saturday, 10 October 2015

HOW TO WRITE THE SELENIUM WEB DRIVER PROGRAMME FOR YAHOO MAIL USING FIREFOX


package pack1;

import org.openqa.selenium.By;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.firefox.FirefoxDriver;

public class web {

            public static void main(String[] args) {
                        WebDriver wd =new FirefoxDriver();
wd.get("http:yahoomail.com");

wd.findElement(By.xpath(".//*[@id='username']")).sendKeys("akhilreddyhyd@yahoo.com");
wd.findElement(By.xpath(".//*[@id='passwd']")).sendKeys("venkanna1434444");
wd.findElement(By.xpath(".//*[@id='.save']")).click();
            }

}

No comments:

Post a Comment