summaryrefslogtreecommitdiff
path: root/sal
diff options
context:
space:
mode:
authorsz <sz@openoffice.org>2002-08-26 14:54:22 +0000
committersz <sz@openoffice.org>2002-08-26 14:54:22 +0000
commitda11036919a16af492da9be321df2362e8a408f4 (patch)
treeb7bb1615fb55f78a1c3c932e424dbefca4386604 /sal
parent1f8022169ea20870cf44c1e6e417e8cb0a6010fc (diff)
#102665# new testshape
Diffstat (limited to 'sal')
-rw-r--r--sal/inc/rtl/tres.h98
1 files changed, 18 insertions, 80 deletions
diff --git a/sal/inc/rtl/tres.h b/sal/inc/rtl/tres.h
index 0555f741bd67..9ecbb00e6714 100644
--- a/sal/inc/rtl/tres.h
+++ b/sal/inc/rtl/tres.h
@@ -5,14 +5,6 @@
#include <osl/diagnose.h>
#endif
-#ifndef _RTL_STRING_H_
-#include <rtl/string.h>
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
/* comandline flags */
#define rtl_tres_Flag_BOOM 0x00000001
#define rtl_tres_Flag_VERBOSE 0x00000002
@@ -27,84 +19,30 @@ extern "C" {
#define rtl_tres_Flag_PASSED 0x10000000
#define rtl_tres_Flag_OK 0x20000000
+#ifdef __cplusplus
+extern "C" {
+#endif
+typedef void* rtlTestResult;
- /* forward declaration and type definition */
-struct _rtl_TestResult;
-typedef struct _rtl_TestResult rtl_TestResult;
-
-
-typedef void* rtl_funcstate;
-typedef void* rtl_cmpstate;
-
- /* type definitions of function pointers wich can be overloaded */
-typedef sal_Bool (SAL_CALL *rtl_tres_state_ptr)(
- rtl_TestResult*,
- sal_Bool,
- const sal_Char*,
- const sal_Char*,
- sal_Bool
- );
-
-typedef void (SAL_CALL *rtl_tres_end_ptr)( rtl_TestResult*, const sal_Char* );
-typedef sal_Bool (SAL_CALL *rtl_tres_ispassed_ptr)( rtl_TestResult* );
-typedef sal_Bool (SAL_CALL *rtl_tres_isok_ptr)( rtl_TestResult* );
-typedef rtl_funcstate (SAL_CALL *rtl_tres_funcstate_ptr)( rtl_TestResult* );
-typedef sal_Bool (SAL_CALL *rtl_tres_isbit_ptr)( rtl_TestResult*,
- sal_uInt32 );
-
-typedef rtl_funcstate (SAL_CALL *rtl_tres_getnextfuncstate_ptr)
- ( rtl_funcstate );
-typedef rtl_funcstate (SAL_CALL *rtl_tres_getprevfuncstate_ptr)
- ( rtl_funcstate );
-typedef sal_uInt32 (SAL_CALL *rtl_tres_getflags_ptr)( rtl_funcstate );
-typedef rtl_String* (SAL_CALL *rtl_tres_getname_ptr)( rtl_funcstate );
-typedef sal_uInt32 (SAL_CALL *rtl_tres_getstart_ptr)( rtl_funcstate );
-typedef sal_uInt32 (SAL_CALL *rtl_tres_getstop_ptr)( rtl_funcstate );
-typedef rtl_cmpstate (SAL_CALL *rtl_tres_getcmpstate_ptr)( rtl_funcstate );
-
-typedef sal_Bool (SAL_CALL *rtl_tres_getstat_ptr)( rtl_cmpstate );
-typedef rtl_String* (SAL_CALL *rtl_tres_getmsg_ptr)( rtl_cmpstate );
-typedef rtl_cmpstate (SAL_CALL *rtl_tres_getnextcmpstate_ptr)( rtl_cmpstate );
-
- /* type definition of vtable structure for testresult */
-typedef struct _rtl_TestResult_vtable
-{
- sal_uInt32 vtablesize;
- rtl_tres_state_ptr state_;
- rtl_tres_end_ptr end_;
- rtl_tres_ispassed_ptr ispassed;
- rtl_tres_isok_ptr isok;
- rtl_tres_funcstate_ptr funcstate;
- rtl_tres_isbit_ptr isbit;
- rtl_tres_getnextfuncstate_ptr nextfuncstate;
- rtl_tres_getprevfuncstate_ptr prevfuncstate;
- rtl_tres_getflags_ptr flags;
- rtl_tres_getname_ptr name;
- rtl_tres_getstart_ptr start;
- rtl_tres_getstop_ptr stop;
- rtl_tres_getcmpstate_ptr cmpstate;
- rtl_tres_getstat_ptr stat;
- rtl_tres_getmsg_ptr msg;
- rtl_tres_getnextcmpstate_ptr nextcmpstate;
-
-} rtl_TestResult_vtable;
-
- /* type definition of testresult structure */
-struct _rtl_TestResult
-{
- rtl_TestResult_vtable * pFuncs;
- void * pExternalData;
-
-};
+rtlTestResult SAL_CALL rtl_tres_create
+ (
+ const sal_Char* meth,
+ sal_uInt32 flags
+ );
+sal_Bool SAL_CALL rtl_tres_state
+ (
+ rtlTestResult res,
+ sal_Bool bSuccess,
+ sal_Char* pTestMsg,
+ sal_Char* pFuncName
+ );
- /* exports */
-rtl_TestResult* SAL_CALL rtl_tres_create( const sal_Char* meth, sal_uInt32 flags );
-void SAL_CALL rtl_tres_destroy( rtl_TestResult* res );
+sal_Bool SAL_CALL rtl_tres_destroy( rtlTestResult res );
#ifdef __cplusplus
}
#endif
-#endif /* _RTL_TRES_H_ */
+#endif