Skip to content Skip to sidebar Skip to footer

Appium Automation Test: How To Get Element Or Text From Custom Ui In Android [android.view.view]

I beginner test automation on Android by Appium. I use IUAtomatorviewer to get eLement from Android Application But i think my applicatoin is from customs UI. i see that is androi

Solution 1:

Get the "recycler view" by its resource-id. You can then get the different view's inside and select the 4th one to view "view #4".

Solution 2:

I was also facing the same issue in getting text from android view. below code helpful for me:

Get all your element in a list :

List<WebElement> allChats : driver.findElements(By.xpath("//*[@class='android.view.View']"));

Then iterate through for loop and get the text using name attribute

for(WebElement chat : allChats)
{
     System.out.println(chat.getAttribute("name"));
}

Post a Comment for "Appium Automation Test: How To Get Element Or Text From Custom Ui In Android [android.view.view]"