]>
Commit | Line | Data |
---|---|---|
f3c0d7a5 A |
1 | // © 2016 and later: Unicode, Inc. and others. |
2 | // License & terms of use: http://www.unicode.org/copyright.html | |
b75a7d8f | 3 | /******************************************************************** |
57a6839d A |
4 | * COPYRIGHT: |
5 | * Copyright (c) 1997-2014, International Business Machines Corporation and | |
b75a7d8f A |
6 | * others. All Rights Reserved. |
7 | ********************************************************************/ | |
8 | /******************************************************************************** | |
9 | * | |
10 | * File CITERTST.H | |
11 | * | |
12 | * Modification History: | |
13 | * Name Description | |
14 | * Madhu Katragadda Converted to C | |
15 | *********************************************************************************/ | |
16 | ||
17 | /** | |
18 | * Collation Iterator tests. | |
19 | * (Let me reiterate my position...) | |
20 | */ | |
21 | ||
22 | #ifndef _CITERCOLLTST | |
23 | #define _CITERCOLLTST | |
24 | ||
25 | #include "unicode/utypes.h" | |
26 | ||
27 | #if !UCONFIG_NO_COLLATION | |
28 | ||
29 | #include "unicode/ucol.h" | |
30 | #include "unicode/ucoleitr.h" | |
31 | #include "cintltst.h" | |
32 | ||
33 | #define MAX_TOKEN_LEN 16 | |
34 | ||
46f4442e A |
35 | /** |
36 | * Test for CollationElementIterator previous and next for the whole set of | |
37 | * unicode characters. | |
38 | */ | |
39 | static void TestUnicodeChar(void); | |
40 | /** | |
41 | * Test for CollationElementIterator previous and next for the whole set of | |
42 | * unicode characters with normalization on. | |
43 | */ | |
44 | static void TestNormalizedUnicodeChar(void); | |
45 | /** | |
46 | * Test incremental normalization | |
47 | */ | |
48 | static void TestNormalization(void); | |
49 | /** | |
50 | * Test for CollationElementIterator.previous() | |
51 | * | |
52 | * @bug 4108758 - Make sure it works with contracting characters | |
53 | * | |
54 | */ | |
55 | static void TestPrevious(void); | |
56 | ||
57 | /** | |
58 | * Test for getOffset() and setOffset() | |
59 | */ | |
60 | static void TestOffset(void); | |
61 | /** | |
62 | * Test for setText() | |
63 | */ | |
64 | static void TestSetText(void); | |
65 | /** @bug 4108762 | |
66 | * Test for getMaxExpansion() | |
67 | */ | |
68 | static void TestMaxExpansion(void); | |
69 | /** | |
70 | * Test Bug 672, where different locales give a different offset after | |
71 | * a previous for the same string at the same position | |
72 | */ | |
73 | static void TestBug672(void); | |
b75a7d8f | 74 | |
46f4442e A |
75 | /** |
76 | * Repeat TestBug672 with normalizatin enabled - this test revealed a bug | |
77 | * in incremental normalization. | |
78 | */ | |
79 | static void TestBug672Normalize(void); | |
80 | /** | |
81 | * Test iterators with an relatively small buffer | |
82 | */ | |
83 | static void TestSmallBuffer(void); | |
84 | /** | |
46f4442e A |
85 | * Tests the discontiguos contractions |
86 | */ | |
87 | static void TestDiscontiguos(void); | |
88 | /** | |
729e4ab9 A |
89 | * TestSearchCollatorElements tests iterator behavior (forwards and backwards) with |
90 | * normalization on AND jamo tailoring, among other things. | |
91 | */ | |
92 | static void TestSearchCollatorElements(void); | |
46f4442e A |
93 | |
94 | /*------------------------------------------------------------------------ | |
95 | Internal utilities | |
96 | */ | |
b75a7d8f | 97 | |
b75a7d8f | 98 | |
46f4442e | 99 | static void assertEqual(UCollationElements *i1, UCollationElements *i2); |
b75a7d8f | 100 | |
b75a7d8f A |
101 | |
102 | #endif /* #if !UCONFIG_NO_COLLATION */ | |
103 | ||
104 | #endif |