/*
**********************************************************************
-* Copyright (C) 1998-2001, International Business Machines Corporation
+* Copyright (C) 1998-2012, International Business Machines Corporation
* and others. All Rights Reserved.
**********************************************************************
*/
#include "rbbiapts.h"
#include "rbbitst.h"
+#define TESTCLASS(n,classname) \
+ case n: \
+ name = #classname; \
+ if (exec) { \
+ logln(#classname "---"); \
+ logln(""); \
+ classname t; \
+ callTest(t, par); \
+ } \
+ break
+
+
void IntlTestRBBI::runIndexedTest( int32_t index, UBool exec, const char* &name, char* par )
{
if (exec) logln("TestSuite RuleBasedBreakIterator: ");
switch (index) {
- case 0:
- name = "RBBIAPITest";
- if (exec) {
- logln("RBBIAPITest--"); logln("");
- RBBIAPITest test;
- callTest( test, par );
- }
- break;
-
- case 1:
- name = "RBBITest";
- if (exec) {
- logln("RBBITest---"); logln("");
- RBBITest test;
- callTest( test, par );
- }
- break;
+ TESTCLASS(0, RBBIAPITest);
+ TESTCLASS(1, RBBITest);
default: name=""; break;
}
}