List of usage examples for org.openqa.selenium By name
public static By name(String name)
From source file:com.phleet.augusta.LoginDriver.java
public void loginPage() throws InterruptedException { driver.findElement(By.name("Sign in")).click(); // Sign in //driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[4]/UIAAlert[1]/UIACollectionView[1]/UIACollectionCell[1]/UIAButton[1]")).click(); driver.findElement(By.name("OK")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)) .sendKeys("kotes.mannam@augustasoftsol.com"); driver.findElement(By.name("Done")).click(); driver.findElement(By.name("Sign in")).click(); driver.findElement(By.name("OK")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).clear(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)) .sendKeys("kotes.mannam@augustasoftsol.com"); driver.findElement(By.name("Done")).click(); ((WebElement) driver.findElements(By.className("UIASecureTextField")).get(0)).sendKeys("1234567"); driver.findElement(By.name("Done")).click(); driver.findElement(By.name("Sign in")).click(); //Thread.sleep(10000); driver.findElement(By.name("Ok")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).clear(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).sendKeys("one@one.com"); driver.findElement(By.name("Done")).click(); ((WebElement) driver.findElements(By.className("UIASecureTextField")).get(0)).clear(); ((WebElement) driver.findElements(By.className("UIASecureTextField")).get(0)).sendKeys("123456"); Thread.sleep(10000);//w w w . java2 s . c o m driver.quit(); }
From source file:com.phleet.augusta.LoginDriver.java
public void BecomeDriver() throws InterruptedException { driver.findElement(By.name("Become a Driver")).click(); Thread.sleep(3000);//from w w w. ja va 2 s.c o m driver.findElement(By.name("Create an Account")).click(); driver.findElement(By.name("Ok")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).sendKeys("kotes"); driver.findElement(By.name("Done")).click(); driver.findElement(By.name("Create an Account")).click(); driver.findElement(By.name("Ok")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(1)).sendKeys("mannam"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(2)).sendKeys("kotes@gmail.com"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(3)).sendKeys("9952172748"); driver.findElement(By.name("Next")).click(); // //UIAApplication[1]/UIAWindow[4]/UIAPicker[1]/UIAPickerWheel[1] // driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[4]/UIAPicker[1]/UIAPickerWheel[3]")).sendKeys("2000"); // driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[4]/UIAPicker[1]/UIAPickerWheel[2]")).sendKeys("August"); // driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[4]/UIAPicker[1]/UIAPickerWheel[1]")).sendKeys("20"); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(0)).sendKeys("5"); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(1)).sendKeys("August"); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(2)).sendKeys("1990"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(5)).sendKeys("Koteswar_141"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(6)).sendKeys("7-141,dallas"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(7)).sendKeys("dallas"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(0)).sendKeys("Texas"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(9)).sendKeys("75255"); driver.findElement(By.name("Done")).click(); //driver.findElement(By.name("Next")).click(); driver.findElement(By.name("Create an Account")).click(); driver.findElement(By.name("Ok")).click(); }
From source file:com.phleet.augusta.LoginDriver.java
public void LocationSet() throws InterruptedException { Thread.sleep(10000);/*from w w w . j a va 2s . com*/ //((WebElement) driver.findElements(By.className("UIATextField")).get(0)).clear(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).clear(); ((WebElement) driver.findElements(By.className("UIATextField")).get(0)).sendKeys("90020"); driver.findElement(By.name("Done")).click(); }
From source file:com.phleet.augusta.LoginDriver.java
public void secondOrder() throws InterruptedException { driver.findElement(By.name("Accept Order")).click(); Thread.sleep(15000);/*ww w .ja v a2 s .co m*/ driver.findElement(By.name("Ok")).click(); Thread.sleep(10000); //driver.quit(); }
From source file:com.phleet.augusta.LoginDriver.java
public void moreOrdersButto() throws InterruptedException { Thread.sleep(15000);// w w w .j a v a 2 s . co m driver.findElement(By.name("More")).click(); Thread.sleep(10000); //driver.quit(); }
From source file:com.phleet.augusta.LoginDriver.java
public void ViewOrderDetails() throws InterruptedException { //driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[1]/UIASegmentedControl[1]/UIAButton[2]")).click(); ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(2)).click(); //((WebElement) driver.findElements(By.className("UIAButton")).get(0)).click(); Thread.sleep(9000);//from www .j a v a 2s . c o m driver.findElement(By.name("View order")).click(); Thread.sleep(15000); ((WebElement) driver.findElements(By.className("UIAButton")).get(0)).click(); Thread.sleep(5000); driver.quit(); }
From source file:com.phleet.augusta.LoginDriver.java
public void License_Insurance_Info() throws InterruptedException { //driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[1]/UIASegmentedControl[1]/UIAButton[2]")).click(); ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(0)).click(); //((WebElement) driver.findElements(By.className("UIAButton")).get(0)).click(); Thread.sleep(9000);/*from w w w .ja v a2 s. com*/ driver.findElement(By.name("nexticon")).click(); Thread.sleep(2000); driver.findElement(By.name("Edit")).click(); Thread.sleep(15000); driver.findElement(By.name("Cancel")).click(); Thread.sleep(5000); driver.findElement(By.name("Edit")).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(9)).clear(); ((WebElement) driver.findElements(By.className("UIATextField")).get(9)).sendKeys("Koteswar"); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(0)).sendKeys("Alaska"); Thread.sleep(2000); driver.findElement(By.name("Next")).click(); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(0)).sendKeys("25"); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(1)).sendKeys("October"); ((WebElement) driver.findElements(By.className("UIAPickerWheel")).get(2)).sendKeys("2040"); driver.findElement(By.name("Done")).click(); Thread.sleep(10000); }
From source file:com.phleet.augusta.LoginDriver.java
public void UploadInsurence() throws InterruptedException { ((WebElement) driver.findElements(By.className("UIATextField")).get(12)).click(); ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(1)).click(); ((WebElement) driver.findElements(By.className("UIATableCell")).get(2)).click(); ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(1)).click(); ((WebElement) driver.findElements(By.className("UIATextField")).get(14)).sendKeys("Augusta"); driver.findElement(By.name("Done")).click(); driver.quit();//from w w w. j av a 2 s . com // wd.findElement(By.xpath("//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[3]")).click(); //wd.findElement(By.xpath("//UIAApplication[1]/UIAWindow[4]/UIAActionSheet[1]/UIACollectionView[1]/UIACollectionCell[2]")).click(); }
From source file:com.phleet.augusta.Slide_Menu.java
public void slide_Menu_Home() throws InterruptedException { Thread.sleep(5000);//ww w . ja va2 s.c o m ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(0)).click(); driver.findElement(By.name("rightBarButtonImage")).click(); Thread.sleep(5000); //driver.scrollTo("Home").click(); driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[1]")).click(); ((WebElement) driver.findElements(By.className("UIACollectionCell")).get(0)).click(); slide_menu.slide_Menu_Profile(); // slide_menu.slide_Menu_Current_Order(); //driver.quit(); }
From source file:com.phleet.augusta.Slide_Menu.java
public void slide_Menu_Current_Order() throws InterruptedException { Thread.sleep(5000);/* w w w. j ava2 s . c o m*/ //((WebElement) driver.findElements(By.className("UIACollectionCell")).get(0)).click(); driver.findElement(By.name("rightBarButtonImage")).click(); Thread.sleep(10000); driver.findElement(By.xpath("//UIAApplication[1]/UIAWindow[1]/UIATableView[1]/UIATableCell[2]")).click(); Thread.sleep(15000); slide_menu.slide_Menu_Profile(); }