]>
git.saurik.com Git - apple/icu.git/blob - icuSources/test/cintltst/cloctst.h
1 // © 2016 and later: Unicode, Inc. and others.
2 // License & terms of use: http://www.unicode.org/copyright.html
3 /********************************************************************
5 * Copyright (c) 1997-2014, International Business Machines Corporation and
6 * others. All Rights Reserved.
7 ********************************************************************/
8 /********************************************************************************
12 * Modification History:
14 * Madhu Katragadda Converted to C
15 *********************************************************************************
21 /*C API TEST FOR LOCALE */
24 * Test functions to set and get data fields
26 static void TestBasicGetters(void);
27 static void TestPrefixes(void);
29 * Use Locale to access Resource file data and compare against expected values
31 static void TestSimpleResourceInfo(void);
33 * Use Locale to access Resource file display names and compare against expected values
35 static void TestDisplayNames(void);
37 * Test getAvailableLocales
39 static void TestGetAvailableLocales(void);
41 * Test functions to set and access a custom data directory
43 static void TestDataDirectory(void);
45 * Test functions to test get ISO countries and Languages
47 static void TestISOFunctions(void);
49 * Test functions to test get ISO3 countries and Languages Fallback
51 static void TestISO3Fallback(void);
53 * Test functions to test get ISO3 countries and Languages for Uninstalled locales
55 static void TestUninstalledISO3Names(void);
56 static void TestObsoleteNames(void);
58 * Test functions uloc_getDisplaynames()
60 static void TestSimpleDisplayNames(void);
62 * Test functions uloc_getDisplaynames()
64 static void TestVariantParsing(void);
66 /* Test getting keyword enumeratin */
67 static void TestKeywordVariants(void);
69 static void TestKeywordSet(void);
70 static void TestKeywordSetError(void);
72 /* Test getting keyword values */
73 static void TestKeywordVariantParsing(void);
75 /* Test warning for no data in getDisplay* */
76 static void TestDisplayNameWarning(void);
78 /* Test uloc_getLocaleForLCID */
79 static void TestGetLocaleForLCID(void);
82 * routine to perform subtests, used by TestDisplayNames
84 static void doTestDisplayNames(const char* inLocale
, int32_t compareIndex
);
86 static void TestCanonicalization(void);
88 static void TestDisplayKeywords(void);
90 static void TestDisplayKeywordValues(void);
92 static void TestGetBaseName(void);
94 static void TestTrailingNull(void);
96 static void TestGetLocale(void);
99 * additional intialization for datatables storing expected values
101 static void setUpDataTable(void);
102 static void cleanUpDataTable(void);
103 /*static void displayDataTable(void);*/
104 static void TestAcceptLanguage(void);
107 * test locale aliases
109 static void TestCalendar(void);
110 static void TestDateFormat(void);
111 static void TestCollation(void);
112 static void TestULocale(void);
113 static void TestUResourceBundle(void);
114 static void TestDisplayName(void);
116 static void TestAcceptLanguage(void);
118 static void TestOrientation(void);
120 static void TestLikelySubtags(void);
125 static void TestForLanguageTag(void);
126 static void TestToLanguageTag(void);
128 static void TestToUnicodeLocaleKey(void);
129 static void TestToLegacyKey(void);
130 static void TestToUnicodeLocaleType(void);
131 static void TestToLegacyType(void);
136 static void TestEnglishExemplarCharacters(void);