Skip to content

Commit e9d6d04

Browse files
author
Tejas Shah
committed
update element sendKeys
1 parent dc77094 commit e9d6d04

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

ios/src/test/java/com/browserstack/SingleTest.java

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,7 @@ public void test() throws Exception {
2121
loginButton.click();
2222
IOSElement emailTextField = (IOSElement) new WebDriverWait(driver, 30).until(
2323
ExpectedConditions.elementToBeClickable(MobileBy.AccessibilityId("Email address")));
24-
25-
// element.sendKeys() method is not supported in Appium 1.6.3
26-
// Workaround for sendKeys() method:
27-
emailTextField.click();
28-
String email = "[email protected]";
29-
for (int i = 0; i < email.length(); i++) {
30-
driver.findElementByXPath("//XCUIElementTypeKey[@name='" + email.charAt(i) + "']").click();
31-
}
24+
emailTextField.sendKeys("[email protected]");
3225

3326
driver.findElementByAccessibilityId("Next").click();
3427
Thread.sleep(5000);

0 commit comments

Comments
 (0)