home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 6 / AACD06.ISO / AACD / Programming / ICU / src / icu / source / test / cintltst / ccaltst.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-08-16  |  3.2 KB  |  84 lines

  1. /*
  2. *****************************************************************************************
  3. *                                                                                       *
  4. * COPYRIGHT:                                                                            *
  5. *   (C) Copyright Taligent, Inc.,  1996                                                 *
  6. *   (C) Copyright International Business Machines Corporation,  1999                    *
  7. *   Licensed Material - Program-Property of IBM - All Rights Reserved.                  *
  8. *   US Government Users Restricted Rights - Use, duplication, or disclosure             *
  9. *   restricted by GSA ADP Schedule Contract with IBM Corp.                              *
  10. *                                                                                       *
  11. *****************************************************************************************
  12. ********************************************************************************
  13. *
  14. * File CAPITEST.H
  15. *
  16. * Modification History:
  17. *        Name                     Description            
  18. *     Madhu Katragadda               Creation
  19. *********************************************************************************
  20. /* C API TEST FOR CALENDAR */
  21. #ifndef _CCALTST
  22. #define _CCALTST
  23.  
  24. #include "cintltst.h"
  25.  
  26.  
  27.     /**
  28.      * The function used to test the Calendar API
  29.      **/
  30.     static void TestCalendar(void);
  31.     /**
  32.      * The function used to test getMillis, setMillis, setDate and setDateTime functions extensively
  33.      **/
  34.     static void TestGetSetDateAPI(void);
  35.     /**
  36.      * This function is used to test and confirm the functioning of 
  37.      * the calendar get and set functions of calendar fields.
  38.      **/
  39.     static void TestFieldGetSet(void);
  40.     /**
  41.      * Execute and test adding and rolling extensively.
  42.      **/
  43.     static void TestAddRollExtensive(void);
  44.     /**
  45.      *Testing the Limits for various Fields of Calendar
  46.      **/
  47.     static void TestGetLimits(void);
  48.     /**
  49.      * Test that the days of the week progress properly when add is called repeatedly
  50.      * for increments of 24 days.
  51.      **/
  52.     static void TestDOWProgression(void);
  53.     /**
  54.      * Confirm that the offset between local time and GMT behaves as expected.
  55.      **/
  56.     static void TestGMTvsLocal(void);
  57.     /**
  58.      * test subroutine used by TestGMTvsLocal()
  59.      */
  60.     void testZones(int32_t, int32_t, int32_t, int32_t, int32_t, int32_t);
  61.  
  62. /*Internal functions used*/
  63.     /**
  64.      * test subroutines used by TestAddRollExtensive()
  65.      **/
  66.     void checkDate(UCalendar* c, int32_t y, int32_t m, int32_t d);
  67.  
  68.     void checkDateTime(UCalendar* c, int32_t y, int32_t m, int32_t d, 
  69.                             int32_t hr, int32_t min, int32_t sec, int32_t ms, 
  70.                                                     UCalendarDateFields field);
  71.  
  72.     /**
  73.      * test subroutines used by TestGetSetDateAPI and TestFieldGetSet
  74.      **/
  75.     void verify1(const char* msg, UCalendar* c, UDateFormat* dat, int32_t year, int32_t month, int32_t day);
  76.  
  77.     void verify2(const char* msg, UCalendar* c, UDateFormat* dat, int32_t year, int32_t month, int32_t day,
  78.                                                                 int32_t hour, int32_t min, int32_t sec, int32_t am_pm);
  79.  
  80.  
  81.  
  82.  
  83. #endif
  84.