CppunitTest_sw_mailmerge: move DECLARE_MAILMERGE_TEST from header file

Change-Id: Ie9767aaf0f78db14ac2bbf844e824f8d39191fd1
This commit is contained in:
Miklos Vajna
2014-11-04 16:54:19 +01:00
parent d1d84fcaa7
commit 1ab6bfc952
2 changed files with 17 additions and 17 deletions

View File

@@ -149,23 +149,6 @@ using namespace css;
CPPUNIT_TEST_SUITE_REGISTRATION(TestName); \
void TestName::verify()
#define DECLARE_MAILMERGE_TEST(TestName, filename, datasource, tablename, BaseClass) \
class TestName : public BaseClass { \
protected: \
virtual OUString getTestName() SAL_OVERRIDE { return OUString::createFromAscii(#TestName); } \
public: \
CPPUNIT_TEST_SUITE(TestName); \
CPPUNIT_TEST(MailMerge); \
CPPUNIT_TEST_SUITE_END(); \
\
void MailMerge() { \
executeMailMergeTest(filename, datasource, tablename); \
} \
void verify() SAL_OVERRIDE; \
}; \
CPPUNIT_TEST_SUITE_REGISTRATION(TestName); \
void TestName::verify()
/**
* Maps database URIs to the registered database names for quick lookups
*/

View File

@@ -37,6 +37,23 @@ class MMTest : public SwModelTestBase
MMTest() : SwModelTestBase("/sw/qa/extras/mailmerge/data/", "writer8") {}
};
#define DECLARE_MAILMERGE_TEST(TestName, filename, datasource, tablename, BaseClass) \
class TestName : public BaseClass { \
protected: \
virtual OUString getTestName() SAL_OVERRIDE { return OUString::createFromAscii(#TestName); } \
public: \
CPPUNIT_TEST_SUITE(TestName); \
CPPUNIT_TEST(MailMerge); \
CPPUNIT_TEST_SUITE_END(); \
\
void MailMerge() { \
executeMailMergeTest(filename, datasource, tablename); \
} \
void verify() SAL_OVERRIDE; \
}; \
CPPUNIT_TEST_SUITE_REGISTRATION(TestName); \
void TestName::verify()
#define DECLARE_DFLT_MAILMERGE_TEST(TestName, filename, datasource, tablename) \
DECLARE_MAILMERGE_TEST(TestName, filename, datasource, tablename, MMTest)