XPATH 2.0 support for case insensitive text attribute matching

Appium v1.8.1

We have run into an issue where we need XPATH to be case insensitive.
The text for TEXTVIEW comes up as camel case in Android 6 and ALL CAPS in Android 7,8.
eg: On the Android UI we have text “AIRPORT”. On Android 6, the text attribute for this TextView comes up as “Airport” on uiautomater and on Android 7 and 8, the text attribute for this TextView comes up as “AIRPORT”.
Is there a solution for this?

Note: XPATH 2.0 has functions that can help with case-insensitive matching but appium doesn’t support it currently

Check what api level you are on and change the xpath accordingly.

xpath 2.0 won’t be supported by Appium unless there is a proper open source library which supports it