]>
git.saurik.com Git - apple/icu.git/blob - icuSources/test/intltest/tsdate.h
1 /********************************************************************
3 * Copyright (c) 1997-2003, International Business Machines Corporation and
4 * others. All Rights Reserved.
5 ********************************************************************/
7 #ifndef _INTLTESTDATEFORMAT
8 #define _INTLTESTDATEFORMAT
10 #include "unicode/utypes.h"
12 #if !UCONFIG_NO_FORMATTING
14 #include "unicode/unistr.h"
15 #include "unicode/datefmt.h"
19 * Performs some tests in many variations on DateFormat
21 class IntlTestDateFormat
: public IntlTest
{
22 void runIndexedTest( int32_t index
, UBool exec
, const char* &name
, char* par
= NULL
);
27 * test DateFormat::getAvailableLocales
29 void testAvailableLocales(/* char* par */);
31 * call testLocale for all locales
33 void monsterTest(/* char *par */);
36 * call tryDate with variations, called by testLocale
38 void testFormat(/* char* par */);
40 * perform tests using date and fFormat, called in many variations
42 void tryDate(UDate date
);
44 * call testFormat for different DateFormat::EStyle's, etc
46 void testLocale(/*char *par, */const Locale
&, const UnicodeString
&);
48 * return a random number
50 double randDouble(void);
52 * generate description for verbose test output
54 void describeTest(void);
57 UnicodeString fTestName
;
58 int32_t fLimit
; // How many iterations it should take to reach convergence
62 // Values in milliseconds (== Date)
64 ONEMINUTE
= 60 * ONESECOND
,
65 ONEHOUR
= 60 * ONEMINUTE
,
68 static const double ONEYEAR
;
77 virtual ~IntlTestDateFormat();
80 #endif /* #if !UCONFIG_NO_FORMATTING */