scuffed-code/icu4c/source/test/intltest/ucdtest.h

83 lines
2.3 KiB
C
Raw Normal View History

/********************************************************************
* COPYRIGHT:
* Copyright (c) 1997-2001, International Business Machines Corporation and
* others. All Rights Reserved.
********************************************************************/
1999-08-16 21:50:52 +00:00
#include "intltest.h"
/** Helper function for TestUnicodeData */
U_CAPI void U_CALLCONV unicodeDataLineFn(void *context,
char *fields[][2], int32_t fieldCount,
UErrorCode *pErrorCode);
1999-08-16 21:50:52 +00:00
/**
* Test API and functionality of class Unicode
**/
class UnicodeTest: public IntlTest {
public:
UnicodeTest();
virtual ~UnicodeTest();
1999-08-16 21:50:52 +00:00
void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par = NULL );
1999-08-16 21:50:52 +00:00
/**
* Test methods toUpperCase() and toLowerCase()
**/
void TestUpperLower(void);
/**
* Test methods isLetter() and isDigit()
**/
void TestLetterNumber(void);
/**
* Tests methods isControl() and isPrintable()
**/
void TestControlPrint(void);
/**
* Tests methods isJavaIdentifierStart(), isJavaIdentifierPart(),
* isUnicodeIdentifierStart() and isUnicodeIdentifierPart()
**/
void TestIdentifier(void);
/**
* Tests methods isDefined(), isBaseForm(), isSpaceChar() and getCellWidth()
**/
void TestMisc(void);
1999-08-16 21:50:52 +00:00
/**
* tests methods getType(), isTitleCase(), and toTitleCase()
* as well as characterDirection()
**/
void TestUnicodeData(void);
/**
* tests methods isSingle(), isLead(), and isTrail()
**/
void TestCodeUnit(void);
/**
* Tests for isSurrogate(), isUnicodeChar(), isError(), isValid()
**/
void TestCodePoint();
/**
* Tests for needMultipleChar(), charLength()
**/
void TestCharLength();
/**
* Tests for getScript()
**/
void TestScript();
1999-08-16 21:50:52 +00:00
private:
/**
* internal utility used by TestUnicodeData
**/
int32_t MakeProp(char* str);
/**
* internal utility used by TestUnicodeData
**/
int32_t MakeDir(char* str);
friend void U_CALLCONV unicodeDataLineFn(void *context,
char *fields[][2], int32_t fieldCount,
UErrorCode *pErrorCode);
1999-08-16 21:50:52 +00:00
};