X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/374ca955a76ecab1204ca8bfa63ff9238d998416..2be6500137966bba13903b24204a44804f9e133a:/icuSources/test/intltest/numrgts.h diff --git a/icuSources/test/intltest/numrgts.h b/icuSources/test/intltest/numrgts.h index 30024b00..96dc2995 100644 --- a/icuSources/test/intltest/numrgts.h +++ b/icuSources/test/intltest/numrgts.h @@ -1,6 +1,6 @@ /*********************************************************************** * COPYRIGHT: - * Copyright (c) 1997-2004, International Business Machines Corporation + * Copyright (c) 1997-2012, International Business Machines Corporation * and others. All Rights Reserved. ***********************************************************************/ @@ -19,8 +19,8 @@ /** * Performs regression test for MessageFormat **/ -class NumberFormatRegressionTest: public IntlTest { - +class NumberFormatRegressionTest: public IntlTest { + // IntlTest override void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par ); public: @@ -90,79 +90,14 @@ public: void Test4243011(void); void Test4243108(void); void TestJ691(void); - + void Test8199(void); + void Test9109(void); + void Test9780(void); + void Test9677(void); protected: - UBool failure(UErrorCode status, const UnicodeString& msg); - UBool failure(UErrorCode status, const UnicodeString& msg, const char *l); - UBool failure(UErrorCode status, const UnicodeString& msg, const Locale& l); -}; - -class MyNumberFormatTest : public NumberFormat -{ -public: - - virtual UClassID getDynamicClassID(void) const; - - virtual UnicodeString& format( double number, - UnicodeString& toAppendTo, - FieldPosition& pos, - UErrorCode& status) const - { - return NumberFormat::format(number, toAppendTo, pos, status); - } - - /* Just keep this here to make some of the compilers happy */ - virtual UnicodeString& format(const Formattable& obj, - UnicodeString& toAppendTo, - FieldPosition& pos, - UErrorCode& status) const - { - return NumberFormat::format(obj, toAppendTo, pos, status); - } - - /* Just use one of the format functions */ - virtual UnicodeString& format( double /* number */, - UnicodeString& toAppendTo, - FieldPosition& /* pos */) const - { - toAppendTo = ""; - return toAppendTo; - } - - /* - public Number parse(String text, ParsePosition parsePosition) - { return new Integer(0); } - */ - - /* Just use one of the parse functions */ - virtual void parse( const UnicodeString& /* text */, - Formattable& result, - ParsePosition& /* parsePosition */) const - { - result.setLong((int32_t)0); - } - - virtual void parse( const UnicodeString& text, - Formattable& result, - UErrorCode& status) const - { - NumberFormat::parse(text, result, status); - } - virtual Format* clone() const - { return NULL; } - - virtual UnicodeString& format(int32_t, - UnicodeString& foo, - FieldPosition&) const - { return foo.remove(); } - - virtual UnicodeString& format(int64_t, - UnicodeString& foo, - FieldPosition&) const - { return foo.remove(); } - - virtual void applyPattern(const UnicodeString&, UParseError&, UErrorCode&){ - } + UBool failure(UErrorCode status, const UnicodeString& msg, UBool possibleDataError=FALSE); + UBool failure(UErrorCode status, const UnicodeString& msg, const char *l, UBool possibleDataError=FALSE); + UBool failure(UErrorCode status, const UnicodeString& msg, const Locale& l, UBool possibleDataError=FALSE); }; #endif /* #if !UCONFIG_NO_FORMATTING */