Home
last modified time | relevance | path

Searched refs:locale (Results 1 – 25 of 34) sorted by relevance

12

/cts/tests/tests/content/src/android/content/res/cts/
DConfigurationTest.java119 cfg1.locale = Locale.forLanguageTag("en"); in testCompareTo()
120 cfg2.locale = Locale.forLanguageTag("en-Shaw"); in testCompareTo()
122 cfg1.locale = Locale.forLanguageTag("en-Shaw"); in testCompareTo()
123 cfg2.locale = Locale.forLanguageTag("en"); in testCompareTo()
126 cfg1.locale = new Locale("", "", "2"); in testCompareTo()
127 cfg2.locale = new Locale("", "", "3"); in testCompareTo()
129 cfg1.locale = new Locale("", "", "3"); in testCompareTo()
130 cfg2.locale = new Locale("", "", "2"); in testCompareTo()
133 cfg1.locale = new Locale("", "2", ""); in testCompareTo()
134 cfg2.locale = new Locale("", "3", ""); in testCompareTo()
[all …]
DConfigTest.java115 mConfig.locale = Locale.ROOT; in TotalConfig()
179 mConfig.locale = new Locale.Builder() in setProperty()
180 .setLocale(mConfig.locale) in setProperty()
185 mConfig.locale = new Locale.Builder() in setProperty()
186 .setLocale(mConfig.locale) in setProperty()
191 mConfig.locale = new Locale.Builder() in setProperty()
192 .setLocale(mConfig.locale) in setProperty()
197 mConfig.locale = new Locale.Builder() in setProperty()
198 .setLocale(mConfig.locale) in setProperty()
1409 for (String locale : locales) { in testGetLocalesConvertsTlToFil()
[all …]
/cts/hostsidetests/hdmicec/src/android/hdmicec/cts/playback/
DHdmiCecSystemInformationTest.java123 private void setSystemLocale(String locale) throws Exception { in setSystemLocale() argument
125 device.executeShellCommand("setprop " + PROPERTY_LOCALE + " " + locale); in setSystemLocale()
133 private static String extractLanguage(String locale) { in extractLanguage() argument
134 return locale.split("[^a-zA-Z]")[0]; in extractLanguage()
144 final String locale = getSystemLocale(); in cect_11_2_6_3_SetValidMenuLanguage() local
145 final String originalLanguage = extractLanguage(locale); in cect_11_2_6_3_SetValidMenuLanguage()
153 setSystemLocale(locale); in cect_11_2_6_3_SetValidMenuLanguage()
164 final String locale = getSystemLocale(); in cect_11_2_6_4_SetInvalidMenuLanguage() local
165 final String originalLanguage = extractLanguage(locale); in cect_11_2_6_4_SetInvalidMenuLanguage()
172 setSystemLocale(locale); in cect_11_2_6_4_SetInvalidMenuLanguage()
[all …]
/cts/tests/tests/text/src/android/text/style/cts/
DSuggestionSpanTest.java56 final Locale locale = Locale.forLanguageTag("az-Arab"); in testConstructorWithContext() local
57 overrideConfig.setLocales(new LocaleList(locale)); in testConstructorWithContext()
64 assertEquals(locale, span.getLocaleObject()); in testConstructorWithContext()
170 private Locale toWellFormedLocale(@Nullable final Locale locale) { in toWellFormedLocale() argument
171 if (locale == null) { in toWellFormedLocale()
175 return Locale.forLanguageTag(locale.toLanguageTag()); in toWellFormedLocale()
186 private void verifyGetLocaleObject(final Locale locale) { in verifyGetLocaleObject() argument
187 final SuggestionSpan span = new SuggestionSpan(locale, new String[0], in verifyGetLocaleObject()
191 assertEquals(toWellFormedLocale(locale), span.getLocaleObject()); in verifyGetLocaleObject()
192 assertEquals(getNonNullLocaleString(locale), span.getLocale()); in verifyGetLocaleObject()
[all …]
/cts/tests/tests/location/src/android/location/cts/
DAddressTest.java250 Locale locale = Locale.US; in testGetLocale() local
251 Address address = new Address(locale); in testGetLocale()
252 assertSame(locale, address.getLocale()); in testGetLocale()
254 locale = Locale.UK; in testGetLocale()
255 address = new Address(locale); in testGetLocale()
256 assertSame(locale, address.getLocale()); in testGetLocale()
307 Locale locale = Locale.KOREA; in testWriteToParcel() local
308 Address address = new Address(locale); in testWriteToParcel()
313 assertEquals(locale.getLanguage(), parcel.readString()); in testWriteToParcel()
314 assertEquals(locale.getCountry(), parcel.readString()); in testWriteToParcel()
/cts/tests/tests/text/src/android/text/format/cts/
DLocaleUtils.java26 public static boolean isCurrentLocale(Context context, Locale locale) { in isCurrentLocale() argument
28 Locale currentLocale = context.getResources().getConfiguration().locale; in isCurrentLocale()
29 return locale.equals(currentLocale); in isCurrentLocale()
DDateFormatTest.java292 for (Locale locale : Locale.getAvailableLocales()) { in test_bug_82144()
293 Locale.setDefault(locale); in test_bug_82144()
309 + " for " + locale); in test_bug_82144()
313 assertTrue(locale.toString() + " day not found", seenDay); in test_bug_82144()
314 assertTrue(locale.toString() + " month not found", seenMonth); in test_bug_82144()
315 assertTrue(locale.toString() + " year not found", seenYear); in test_bug_82144()
/cts/hostsidetests/hdmicec/src/android/hdmicec/cts/audio/
DHdmiCecInvalidMessagesTest.java79 private void setSystemLocale(String locale) throws Exception { in setSystemLocale() argument
81 device.executeShellCommand("setprop " + PROPERTY_LOCALE + " " + locale); in setSystemLocale()
89 private static String extractLanguage(String locale) { in extractLanguage() argument
90 return locale.split("[^a-zA-Z]")[0]; in extractLanguage()
112 final String locale = getSystemLocale(); in cect_12_1_BroadcastReceivedAsDirectlyAddressed() local
113 final String originalLanguage = extractLanguage(locale); in cect_12_1_BroadcastReceivedAsDirectlyAddressed()
124 setSystemLocale(locale); in cect_12_1_BroadcastReceivedAsDirectlyAddressed()
/cts/tests/tests/speech/src/android/speech/tts/cts/
DStubTextToSpeechService.java114 Locale locale = new Locale(lang, country); in onGetDefaultVoiceNameFor() local
115 if (supportedCountries.contains(locale)) { in onGetDefaultVoiceNameFor()
116 return locale.toLanguageTag(); in onGetDefaultVoiceNameFor()
/cts/tests/tests/text/src/android/text/cts/
DMyanmarTest.java74 final Locale locale = Locale.forLanguageTag(localeName); in setupLocales() local
75 final String script = ULocale.addLikelySubtags(ULocale.forLocale(locale)).getScript(); in setupLocales()
78 sZawgyiLocales.add(locale); in setupLocales()
80 sMymrLocales.add(locale); in setupLocales()
DStaticLayoutLineBreakingVariantsTest.java55 private static void assertLineBreak(String text, String locale, int width, String... expected) { in assertLineBreak() argument
56 final StaticLayout layout = buildLayout(text, LocaleList.forLanguageTags(locale), width); in assertLineBreak()
DAutoTextTest.java52 if (!config.locale.equals(Locale.getDefault())) { in setup()
53 config.locale = Locale.getDefault(); in setup()
/cts/hostsidetests/appsecurity/test-apps/IsolatedSplitApp/
DAndroid.bp28 // Make sure our test locale polish is not stripped.
35 // Generate a locale split.
/cts/hostsidetests/appsecurity/test-apps/IsolatedSplitApp/feature_c/
DAndroid.bp26 // Make sure our test locale polish is not stripped.
29 // Generate a locale split.
/cts/tests/tests/provider/src/android/provider/cts/
DUserDictionary_WordsTest.java86 private void assertWord(String word, int frequency, String shortcut, Locale locale, in assertWord() argument
89 UserDictionary.Words.addWord(mContext, word, frequency, shortcut, locale); in assertWord()
/cts/hostsidetests/appsecurity/test-apps/IsolatedSplitApp/feature_b/
DAndroid.bp26 // Make sure our test locale polish is not stripped.
29 // Generate a locale split.
/cts/hostsidetests/appsecurity/test-apps/IsolatedSplitApp/feature_a/
DAndroid.bp28 // Make sure our test locale polish is not stripped.
31 // Generate a locale split.
/cts/tests/tests/text/src/android/text/method/cts/
DDateKeyListenerTest.java196 MockDateKeyListener(Locale locale) { in MockDateKeyListener() argument
197 super(locale); in MockDateKeyListener()
DTimeKeyListenerTest.java211 MockTimeKeyListener(Locale locale) { in MockTimeKeyListener() argument
212 super(locale); in MockTimeKeyListener()
DDateTimeKeyListenerTest.java216 MockDateTimeKeyListener(Locale locale) { in MockDateTimeKeyListener() argument
217 super(locale); in MockDateTimeKeyListener()
/cts/tests/tests/view/src/android/view/textclassifier/cts/
DTextClassificationManagerTest.java286 final ULocale locale = language.getLocale(i); in assertValidResult() local
287 assertNotNull(locale); in assertValidResult()
288 final float confidenceScore = language.getConfidenceScore(locale); in assertValidResult()
/cts/tests/tests/os/src/android/os/cts/
DLocaleListTest.java334 final Locale locale = localeList.get(index); in resetDefaultLocaleList() local
335 if (topLocale != null && !topLocale.equals(locale)) { in resetDefaultLocaleList()
336 newLocales.add(locale); in resetDefaultLocaleList()
/cts/tests/tests/content/
DAndroid.bp48 // Resource unit tests use a private locale and some densities
/cts/hostsidetests/appsecurity/test-apps/SplitApp/src/com/android/cts/splitapp/
DSplitAppTest.java562 private static void updateLocale(Resources r, Locale locale) { in updateLocale() argument
564 c.locale = locale; in updateLocale()
/cts/tools/release-parser/tests/resources/
Dbuild.prop35 ro.product.locale=en-US

12