Semi transparent element is not interactable - Android Mobile Test Autmation

Hello everyone,

I have been developing a mobile test automation project. If you are testing the case manually you can interact with element, I mean the element is pyhsically visible however when it comes to automation element is invibisible and no way to interact.

  • when I set appium capabilities as below I can interact with the semi transparent elements.

       ` appium:settings[allowInvisibleElements]: true;`
    

The problem is that when you set capabilities as above, all invisible, transparent or semi transparent elements become visible and interactable which I don’t want.

I have problem with only one semi transparent element and I need to click and check the text on it.

Is there a way to handle the situation?

Thanks in advance.

I think it is not possible(if I understood you properly). I think the best way is to enable this setting(I do the same personally) and check the “.isDisplayed()” return value. to know if an element is “semi-transparent” you can check its subelements which you know should be visible and based on that you can know if an element is invisible or semi-trasparent.

you can try detail more specification regarding your test case which may help understand better the how to handle it.