Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(218)

Side by Side Diff: source/test/intltest/calcasts.h

Issue 2435373002: Delete source/test (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « source/test/intltest/bytestrietest.cpp ('k') | source/test/intltest/calcasts.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /********************************************************************
2 * COPYRIGHT:
3 * Copyright (c) 2003-2008, International Business Machines Corporation
4 * and others. All Rights Reserved.
5 ********************************************************************
6 * Calendar Case Test is a type of CalendarTest which compares the
7 * behavior of a calendar to a certain set of 'test cases', involving
8 * conversion between julian-day to fields and vice versa.
9 ********************************************************************/
10
11 #ifndef __CalendarCaseTest__
12 #define __CalendarCaseTest__
13
14 #include "unicode/utypes.h"
15
16 #if !UCONFIG_NO_FORMATTING
17
18 #include "unicode/calendar.h"
19 #include "unicode/smpdtfmt.h"
20 #include "caltest.h"
21
22 class CalendarCaseTest: public CalendarTest {
23 public:
24 virtual void runIndexedTest( int32_t index, UBool exec, const char* &name, cha r* par );
25
26 /* Test case struct */
27 struct TestCase {
28 double julian; // Julian Date
29 int32_t era;
30 int32_t year;
31 int32_t month;
32 int32_t day;
33 int32_t dayOfWeek;
34 int32_t hour;
35 int32_t min;
36 int32_t sec;
37 };
38
39 /**
40 * @param cases array of items to test. Terminate with a "-1" for era.
41 */
42 void doTestCases(const TestCase *cases, Calendar *cal);
43
44 private:
45 /**
46 * Utility function to test out a specific field
47 * @param cal calendar
48 * @param field which field
49 * @param value expected value
50 * @param status err status
51 * @return boolean indicating success (TRUE) or failure (FALSE) of the test.
52 */
53 UBool checkField(Calendar *cal, UCalendarDateFields field, int32_t value, UErr orCode &status);
54
55 private:
56 // test cases
57 void IslamicCivil();
58 void Hebrew();
59 void Indian();
60 void Coptic();
61 void Ethiopic();
62 };
63
64 #endif
65 #endif
OLDNEW
« no previous file with comments | « source/test/intltest/bytestrietest.cpp ('k') | source/test/intltest/calcasts.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698