Location service popup

What is the best way of dealing with the ‘Location Service Popup’

is there a way to not show this popup when running the tests?
any feedback is welcome

FYI, I’m using iOS 14 & Python


If you reinstall app during test or test before = no way. Otherwise tap second choise once.

No, but you can auto_accept:

autoAcceptAlerts	Accept all iOS alerts automatically if they pop up. 
This includes privacy access permission alerts (e.g., location, contacts, photos).
Default is false.	true or false


I was able to handle this :heart_eyes:

set Desired Capabilities option autoAcceptAlerts to True

set a different locator for the accept button

                "acceptAlertButtonSelector": "**/XCUIElementTypeButton[`label == 'Allow While Using App'`]"