Hi,
I’m automating a hybrid app using the Javascript wd. On iOS simulator, I can tap an external web link in my app and it opens a new safari window with the target link. When this happens, I notice in the appium log that I get info like this:
`[debug] [RemoteDebugger] Page changed: {“1”:{“WIRTitleKey”:“My Store - Shop”,“WIRTypeKey”:“WIRTypeWeb”,“WIRURLKey”:“https://shop.mycompany.com/collections/widgets?utm_source=myApp&utm_medium=appBanner&utm_campaign=",“WIRPageIdentifierKey”:1,“WIRConnectionIdentifierKey”:"D2872FE1-18FB-46F5-973A-9923B83676E7”}}
[debug] [iOS] Remote debugger notified us of a new page listing: {“appIdKey”:“30424”,“pageArray”:[{“id”:1,“title”:“My Store - Shop”,“url”:“https://shop.mycompany.com/collections/widgets?utm_source=myApp&utm_medium=appBanner&utm_campaign=","isKey”:true}]}`
Without interacting with the mobile safari window, is it possible for me to get the url out of this data object within appium? How? All I need to do is verify the URL matches what is in the spec. I’m hoping that since this data is being logged, it is also available programmatically with some kind of driver.whatever() method. I’m really really hoping I don’t have to write some kind of logfile monitor and pull it out of there.
Thanks!
-Jerimiah