I’m automating an In-App Purchase Test on IOS devices. The test needs to work for both old and new ios devices. That is: the test needs to be able to handle both XCUITest and UiAutomation, when it comes to handling different popups appearing when doing In-App purchase. Popups, such as “sign in to iTunes”, “Confirm your In-App Purchase” etc.
The elements in these popups have different names depending on if XCUITest or UiAutomation is used.
My approach so far is: Findout in runtime if appium is using XCUITest or UiAutomation. Then handle the popups accordingly.
So question is: is there an easy way to findout in runtime if appium is using XCUITest or Uiautomation?
Or should I be taking some completely different approach? Any help is appreciated.
/Alex