]>
Commit | Line | Data |
---|---|---|
1 | // © 2016 and later: Unicode, Inc. and others. | |
2 | // License & terms of use: http://www.unicode.org/copyright.html | |
3 | /******************************************************************** | |
4 | * COPYRIGHT: | |
5 | * Copyright (c) 1997-2001, International Business Machines Corporation and | |
6 | * others. All Rights Reserved. | |
7 | ********************************************************************/ | |
8 | ||
9 | /** | |
10 | * MajorTestLevel is the top level test class for everything in the directory "IntlWork". | |
11 | */ | |
12 | ||
13 | #ifndef _INTLTESTFORMAT | |
14 | #define _INTLTESTFORMAT | |
15 | ||
16 | #include "unicode/utypes.h" | |
17 | ||
18 | #if !UCONFIG_NO_FORMATTING | |
19 | ||
20 | #include "unicode/formattedvalue.h" | |
21 | #include "intltest.h" | |
22 | ||
23 | ||
24 | class IntlTestFormat: public IntlTest { | |
25 | void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par = NULL ); | |
26 | }; | |
27 | ||
28 | ||
29 | typedef struct UFieldPositionWithCategory { | |
30 | UFieldCategory category; | |
31 | int32_t field; | |
32 | int32_t beginIndex; | |
33 | int32_t endIndex; | |
34 | } UFieldPositionWithCategory; | |
35 | ||
36 | class IntlTestWithFieldPosition : public IntlTest { | |
37 | public: | |
38 | void checkFormattedValue( | |
39 | const char16_t* message, | |
40 | const FormattedValue& fv, | |
41 | UnicodeString expectedString, | |
42 | UFieldCategory expectedCategory, | |
43 | const UFieldPosition* expectedFieldPositions, | |
44 | int32_t length); | |
45 | ||
46 | void checkMixedFormattedValue( | |
47 | const char16_t* message, | |
48 | const FormattedValue& fv, | |
49 | UnicodeString expectedString, | |
50 | const UFieldPositionWithCategory* expectedFieldPositions, | |
51 | int32_t length); | |
52 | }; | |
53 | ||
54 | ||
55 | #endif /* #if !UCONFIG_NO_FORMATTING */ | |
56 | ||
57 | #endif |