1 /******************************************************************** 2 * COPYRIGHT: 3 * Copyright (c) 2002-2010, International Business Machines Corporation and 4 * others. All Rights Reserved. 5 ********************************************************************/ 6 7 8 #ifndef _UOBJECTTEST_ 9 #define _UOBJECTTEST_ 10 11 #include "intltest.h" 12 13 /** 14 * Test uobjtest.h 15 **/ 16 class UObjectTest : public IntlTest { 17 // IntlTest override 18 void runIndexedTest( int32_t index, UBool exec, const char* &name, char* par ); 19 private: 20 // tests 21 void testIDs(); 22 void testUMemory(); 23 void TestMFCCompatibility(); 24 void TestCompilerRTTI(); 25 26 //helper 27 28 /** 29 * @param obj The UObject to be tested 30 * @param className The name of the class being tested 31 * @param factory String version of obj, for exanple "new UFoo(1,3,4)". NULL if object is abstract. 32 * @param staticID The result of class :: getStaticClassID 33 * @return Returns obj, suitable for deletion 34 */ 35 UObject *testClass(UObject *obj, 36 const char *className, const char *factory, 37 UClassID staticID); 38 39 UObject *testClassNoClassID(UObject *obj, 40 const char *className, const char *factory); 41 }; 42 43 #endif 44 //eof 45