]> git.saurik.com Git - apple/icu.git/blobdiff - icuSources/test/intltest/itformat.h
ICU-64232.0.1.tar.gz
[apple/icu.git] / icuSources / test / intltest / itformat.h
index 5af7601fb56bbe4158d9cd5326735323e11e46c7..d8b17993c30f8374bea9085e2d4e6d00b13641bd 100644 (file)
@@ -17,6 +17,7 @@
 
 #if !UCONFIG_NO_FORMATTING
 
+#include "unicode/formattedvalue.h"
 #include "intltest.h"
 
 
@@ -24,6 +25,33 @@ class IntlTestFormat: public IntlTest {
     void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par = NULL );
 };
 
+
+typedef struct UFieldPositionWithCategory {
+    UFieldCategory category;
+    int32_t field;
+    int32_t beginIndex;
+    int32_t endIndex;
+} UFieldPositionWithCategory;
+
+class IntlTestWithFieldPosition : public IntlTest {
+public:
+    void checkFormattedValue(
+        const char16_t* message,
+        const FormattedValue& fv,
+        UnicodeString expectedString,
+        UFieldCategory expectedCategory,
+        const UFieldPosition* expectedFieldPositions,
+        int32_t length);
+
+    void checkMixedFormattedValue(
+        const char16_t* message,
+        const FormattedValue& fv,
+        UnicodeString expectedString,
+        const UFieldPositionWithCategory* expectedFieldPositions,
+        int32_t length);
+};
+
+
 #endif /* #if !UCONFIG_NO_FORMATTING */
 
 #endif