]>
Commit | Line | Data |
---|---|---|
46f4442e A |
1 | /******************************************************************** |
2 | * COPYRIGHT: | |
51004dcb | 3 | * Copyright (c) 1997-2012, International Business Machines Corporation and |
46f4442e A |
4 | * others. All Rights Reserved. |
5 | ********************************************************************/ | |
6 | ||
7 | #ifndef _PLURALFORMATTEST | |
8 | #define _PLURALFORMATTEST | |
9 | ||
10 | #include "unicode/utypes.h" | |
11 | #include "unicode/plurrule.h" | |
12 | #include "unicode/plurfmt.h" | |
13 | ||
14 | ||
15 | #if !UCONFIG_NO_FORMATTING | |
16 | ||
17 | #include "intltest.h" | |
18 | ||
19 | /** | |
20 | * Test basic functionality of various API functions | |
21 | **/ | |
22 | class PluralFormatTest : public IntlTest { | |
23 | void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par = NULL ); | |
24 | ||
25 | private: | |
26 | /** | |
27 | * Performs tests on many API functions, see detailed comments in source code | |
28 | **/ | |
29 | void pluralFormatBasicTest(/* char* par */); | |
30 | void pluralFormatUnitTest(/* char* par */); | |
31 | void pluralFormatLocaleTest(/* char* par */); | |
4388f060 A |
32 | void pluralFormatExtendedTest(); |
33 | void pluralFormatExtendedParseTest(); | |
51004dcb | 34 | void ordinalFormatTest(); |
46f4442e A |
35 | void numberFormatTest(PluralFormat* plFmt, |
36 | NumberFormat *numFmt, | |
37 | int32_t start, | |
38 | int32_t end, | |
39 | UnicodeString* numOddAppendStr, | |
40 | UnicodeString* numEvenAppendStr, | |
41 | UBool overwrite, // overwrite the numberFormat.format result | |
42 | UnicodeString *message); | |
51004dcb | 43 | void helperTestResults(const char** localeArray, |
46f4442e A |
44 | int32_t capacityOfArray, |
45 | UnicodeString& testPattern, | |
46 | int8_t *expectingResults); | |
47 | }; | |
48 | ||
49 | #endif /* #if !UCONFIG_NO_FORMATTING */ | |
50 | ||
51 | #endif |