Localization
JamaicanRumCream opened this issue · 2 comments
I'm working on using Fastlane:Snapshot, and this projects is a great guide. But I am wondering how to target alerts in different languages when the text or button text isn't the same. IE,
app.alerts["You won!"].buttons["Awesome!"].tap()
or
addUIInterruptionMonitorWithDescription("Location Services") { (alert) -> Bool in alert.buttons["Allow"].tap() return true }
Especially considering the system alert buttons might not be the same translation even if I have NSLocaliazedString...
One of the ways you can target an element it's via it's accessibility identifier, look for Queries
in https://www.bignerdranch.com/blog/ui-testing-in-xcode-7-part-1-ui-testing-gotchas/.
Those are retained regardless of the actual text on the element.
I'm going to close this thanks to @leopic's comment. Please open a new issue if that didn't work of you, @JamaicanRumCream.