1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152
|
// © 2016 and later: Unicode, Inc. and others.
// License & terms of use: http://www.unicode.org/copyright.html
/********************************************************************
* Copyright (c) 1997-2013 International Business Machines
* Corporation and others. All Rights Reserved.
********************************************************************/
/********************************************************************************
*
* File CAPITEST.H
*
* Modification History:
* Name Description
* Madhu Katragadda Converted to C
* Brian Rower Added TestOpenVsOpenRules
*********************************************************************************
*//* C API TEST For COLLATOR */
#ifndef _CCOLLAPITST
#define _CCOLLAPITST
#include "unicode/utypes.h"
#if !UCONFIG_NO_COLLATION
#include "cintltst.h"
#include "callcoll.h"
#define MAX_TOKEN_LEN 16
/**
* error reporting utility method
**/
static void doAssert(int condition, const char *message);
/**
* Collator Class Properties
* ctor, dtor, createInstance, compare, getStrength/setStrength
* getDecomposition/setDecomposition, getDisplayName
*/
void TestProperty(void);
/**
* Test RuleBasedCollator and getRules
**/
void TestRuleBasedColl(void);
/**
* Test compare
**/
void TestCompare(void);
/**
* Test hashCode functionality
**/
void TestHashCode(void);
/**
* Tests the constructor and numerous other methods for CollationKey
**/
void TestSortKey(void);
/**
* test the CollationElementIterator methods
**/
void TestElemIter(void);
/**
* Test ucol_getAvailable and ucol_countAvailable()
**/
void TestGetAll(void);
/**
* Test ucol_GetDefaultRules ()
void TestGetDefaultRules(void);
**/
void TestDecomposition(void);
/**
* Test ucol_safeClone ()
**/
void TestSafeClone(void);
/**
* Test ucol_clone ()
**/
void TestClone(void);
/**
* Test ucol_cloneBinary(), ucol_openBinary()
**/
void TestCloneBinary(void);
/**
* Test ucol_open() vs. ucol_openRules()
**/
void TestOpenVsOpenRules(void);
/**
* Test getting bounds for a sortkey
*/
void TestBounds(void);
/**
* Test ucol_getLocale function
*/
void TestGetLocale(void);
/**
* Test buffer overrun while having smaller buffer for sortkey (j1865)
*/
void TestSortKeyBufferOverrun(void);
/**
* Test getting and setting of attributes
*/
void TestGetSetAttr(void);
/**
* Test getTailoredSet
*/
void TestGetTailoredSet(void);
/**
* Test mergeSortKeys
*/
void TestMergeSortKeys(void);
/**
* test short string and collator identifier functions
*/
static void TestShortString(void);
/**
* test getContractions and getUnsafeSet
*/
static void TestGetContractionsAndUnsafes(void);
/**
* Test funny stuff with open binary
*/
static void TestOpenBinary(void);
/**
* Test getKeywordValuesForLocale API
*/
static void TestGetKeywordValuesForLocale(void);
/**
* test strcoll with null arg
*/
static void TestStrcollNull(void);
/**
* Simple test for ICU-21460. The issue affects all components, but was originally reported against collation.
*/
static void TestLocaleIDWithUnderscoreAndExtension(void);
#endif /* #if !UCONFIG_NO_COLLATION */
#endif
|