blob: d6bd1179f910dbd360d9dd95605e40ad81929613 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
#include <cppunit/Portability.h>
#if !defined(CPPUNIT_NO_TESTPLUGIN)
#include <cppunit/extensions/TestFactoryRegistry.h>
#include <cppunit/TestSuite.h>
#include <cppunit/plugin/TestPlugInDefaultImpl.h>
namespace CppUnit
{
TestPlugInDefaultImpl::TestPlugInDefaultImpl()
: m_suite( NULL )
{
}
TestPlugInDefaultImpl::~TestPlugInDefaultImpl()
{
delete m_suite;
m_suite = NULL;
}
void
TestPlugInDefaultImpl::initialize()
{
m_suite = new TestSuite( getSuiteName() );
TestFactoryRegistry::getRegistry().addTestToSuite( m_suite );
}
Test *
TestPlugInDefaultImpl::getTestSuite()
{
return m_suite;
}
void
TestPlugInDefaultImpl::uninitialize()
{
delete m_suite;
m_suite = NULL;
}
std::string
TestPlugInDefaultImpl::getSuiteName()
{
return "All Tests";
}
} // namespace CppUnit
#endif // !defined(CPPUNIT_NO_TESTPLUGIN)
|