blob: 7e3368cb6c62eb51a64d4ee6d818ea313826947b (
plain)
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
|
/********************************************************************
* COPYRIGHT:
* Copyright (c) 2002-2003, International Business Machines Corporation and
* others. All Rights Reserved.
********************************************************************/
/**
* UCAConformanceTest performs conformance tests defined in the data
* files. ICU ships with stub data files, as the whole test are too
* long. To do the whole test, download the test files.
*/
#ifndef _UCACONF_TST
#define _UCACONF_TST
#include "unicode/utypes.h"
#if !UCONFIG_NO_COLLATION
#include "unicode/tblcoll.h"
#include "tscoll.h"
#include <stdio.h>
class UCAConformanceTest: public IntlTestCollator {
public:
UCAConformanceTest();
virtual ~UCAConformanceTest();
void runIndexedTest( int32_t index, UBool exec, const char* &name, char* /*par = NULL */);
void TestTableNonIgnorable(/* par */);
void TestTableShifted(/* par */);
void TestRulesNonIgnorable(/* par */);
void TestRulesShifted(/* par */);
private:
void initRbUCA();
void setCollNonIgnorable(UCollator *coll);
void setCollShifted(UCollator *coll);
void testConformance(UCollator *coll);
void openTestFile(const char *type);
UCollator *UCA;
UCollator *rbUCA;
FILE *testFile;
UErrorCode status;
char testDataPath[1024];
};
#endif /* #if !UCONFIG_NO_COLLATION */
#endif
|