Open Nemorokr opened 6 months ago
You can use xcodebuild test-without-building arguments.
For example, your marathonfile may look like:
name: "My application"
outputDir: "derived-data/Marathon"
vendorConfiguration:
type: "iOS"
xcodebuildTestArgs:
"-testLanguage": "fr"
"-testRegion": "FR"
bundle:
application: "sample.zip"
testApplication: "sampleUITests-Runner.zip"
testType: xcuitest
These settings are for app's language. My request was about simulator's language
@Nemorokr, could you provide an example of where these settings may be used and which cases may be covered? I mean real cases from your current experience, not theoretical cases.
Hello Our cases with simulator's language
permissions
setting)Bundle.localizedString(forKey:value:table:)
in the main app we get "title_ru". When we use in test app we get "title_en". As a result we are trying to compare "title_ru" with "title_en". Xcodebuild arguments like -testLanguage
and -testRegion
do not set lang for test runner appI'm pretty sure you can hardcode your language in the test app, get bundle resources for that language andget the appropriate title
for the language. You essentially hardcode via environment setup, but your code should be flexible and detect which language it's using and use appropriate ones, i.e. for interacting with the app use one language and for the rest of interaction with the system - device's locale. That said, we're going to look into this issue
Also, can you please create issue(s) with additional permissions needed?
Is your feature request related to a problem? Please describe. Need to be able to set simulator's locale before starting tests
Describe the solution you'd like Maybe some sort of config inside Vendor's block of Marathonfile
Describe alternatives you've considered N/A
Additional context N/A