Expected behavior
The locale should also be set correctly for those languages
Additional context
All the methods/components to set the Locale use the same methods as fastlane/Screengrab for converting strings into Locales. It means, they do not use Locale.forLanguageTag(), which supports such complex locales, but its own Localeutil method.
It is worth noticing that Locale.forLanguageTag() only supports IETF locale strings e.g. "en-US" but not ISO locale strings e.g. "en_US".
Moreover, the pseudolocales "en_XA" and "ar_XB" only exist as ISO locale Strings.
That is important to add support for complex locales, while still supporting ISO locales (at least as good as till AndroidUiTestingUtils 1.2.1) as well as pseudolocales
Describe the bug Complex locales, like "sr-Latn-RS" / "sr-Cyrl-RS" or "zh-Latn-TW-pinyin" cannot be set.
Environment The setup in which the bug is reproducible:
Expected behavior The locale should also be set correctly for those languages
Additional context All the methods/components to set the Locale use the same methods as fastlane/Screengrab for converting strings into Locales. It means, they do not use
Locale.forLanguageTag()
, which supports such complex locales, but its own Localeutil method. It is worth noticing thatLocale.forLanguageTag()
only supports IETF locale strings e.g. "en-US" but not ISO locale strings e.g. "en_US".Moreover, the pseudolocales "en_XA" and "ar_XB" only exist as ISO locale Strings.
That is important to add support for complex locales, while still supporting ISO locales (at least as good as till AndroidUiTestingUtils 1.2.1) as well as pseudolocales