CppUnit project page | FAQ | CppUnit home page

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- File List
- File Members

TestDecorator.h
Go to the documentation of this file.
1 #ifndef CPPUNIT_EXTENSIONS_TESTDECORATOR_H
2 #define CPPUNIT_EXTENSIONS_TESTDECORATOR_H
3
4 #include <cppunit/Portability.h>
5 #include <cppunit/Test.h>
6
7 CPPUNIT_NS_BEGIN
8
9
10 class TestResult;
11
12
21 class CPPUNIT_API TestDecorator : public Test
22 {
23 public:
24 TestDecorator( Test *test );
25 ~TestDecorator();
26
27 int countTestCases() const;
28
29 std::string getName() const;
30
31 void run( TestResult *result );
32
33 int getChildTestCount() const;
34
35 protected:
36 Test *doGetChildTestAt( int index ) const;
37
38 Test *m_test;
39
40 private:
41 TestDecorator( const TestDecorator &);
42 void operator =( const TestDecorator & );
43 };
44
45
46 CPPUNIT_NS_END
47
48 #endif
49
TestResult
Manages TestListener.A single instance of this class is used when running the test. It is usually created by the test runner (TestRunner).
Definition: TestResult.h:51
Portability.h
Test::countTestCases
virtual int countTestCases() const =0
Return the number of test cases invoked by run().
Test
Base class for all test objects.All test objects should be a subclass of Test. Some test objects...
Definition: Test.h:25
Test::getName
virtual std::string getName() const =0
Returns the test name.
CPPUNIT_NS_END
#define CPPUNIT_NS_END
Definition: Portability.h:120
CPPUNIT_NS_BEGIN
#define CPPUNIT_NS_BEGIN
Definition: Portability.h:119
TestDecorator::m_test
Test * m_test
Definition: TestDecorator.h:38
Test::run
virtual void run(TestResult *result)=0
Run the test, collecting results.
Test::doGetChildTestAt
virtual Test * doGetChildTestAt(int index) const =0
Returns the child test of the specified valid index.
Test.h
Test::getChildTestCount
virtual int getChildTestCount() const =0
Returns the number of direct child of the test.
TestDecorator
Decorator for Tests.
Definition: TestDecorator.h:21
CPPUNIT_API
#define CPPUNIT_API
Definition: CppUnitApi.h:27

| hosts this site. |  | Send comments to: CppUnit Developers