Appium can't locate & access elements using accessibility id attribute on IOS

2.9k Views Asked by At

The automation tests used to work until recently (~ one month ago). The issue is that the elements are not located when using Appium inspect element tool and also when tests are running on IOS.

Accessibility ID selector is shown in Appium inspect tool, but when you try to search for the element using the same selector, element is not found.

NOTE: Using 'content-desc' for the same elements works fine on Android.

Any idea how to solve this issue?

Dependencies:

Appium v.1.18.3
"[email protected]",
"selenium-appium": "0.0.15",
"selenium-webdriver": "4.0.0-alpha.7",

App dependencies:

"react": "16.13.1",
"react-content-loader": "^5.1.0",
"react-native": "0.63.3",
"react-native-background-timer": "^2.2.0",
"react-native-config": "^1.3.1",

enter image description here

1

There are 1 best solutions below

0
On

As I know this issue occurs when you simply copy paste accessibility id from list and paste in id seach box.

Check my below observation

1.Simply copy and paste the id which includes space before id.

Here in this image id is present with space

Result-:

You will find there is no element as shown in image

  1. Now remove early space before id . Please check screenshot for same id as below

I have removed spaces and then clicking on search

Now you see element is there with id shown in image.

Hope I have cleared your doubt