Trying to do the Testing of Android Application coded in WebView. I have an app that I am trying to automate the Test Cases.
I have a login screen having Email and Password which does have id locaters. That is working fine I am able to locate elements. ITs hybrid app made with ionic. The login button does not have id locater.
So far I have tried this thing.
MobileWebBrowserFactory factory;
AndroidDriver<WebElement> appiumdriver;
WebElement LoginElement = appiumdriver.findElement(By.id("username"));
LoginElement.click();
LoginElement.sendKeys("Test");
WebElement PasswordElement = appiumdriver.findElement(By.id("password"));
PasswordElement.click();
PasswordElement.sendKeys("Test");
// Hide Keyboard
appiumdriver.hideKeyboard();
Thread.sleep(2000);
WebElement LoginButton = appiumdriver
.findElementByName("end");
it giving me exception that name is not allowed locator to find all the times. I have used Android and appium drivers both.
Can any one Suggest me good libraries for this? I appreciate your help in advance.
Thanks
from Locator is not working except id on the Appium for Android in WebView
No comments:
Post a Comment