CppUnit project page | FAQ | CppUnit home page

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

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# TestCaseDecorator Class Reference

Decorator for Test cases. More...

`#include <TestCaseDecorator.h>`

Inheritance diagram for TestCaseDecorator:

[legend]
Collaboration diagram for TestCaseDecorator:

[legend]
List of all members.

## Public Member Functions
| TestCaseDecorator (TestCase *test)
| ~TestCaseDecorator ()
std::string | getName () const
| Returns the name of the test case.
void | setUp ()
| Set up context before running a test.
void | tearDown ()
| Clean up after the test run.
void | runTest ()
| FIXME: this should probably be pure virtual.
## Protected Attributes
TestCase * | m_test

## Detailed Description

Decorator for Test cases.

TestCaseDecorator provides an alternate means to extend functionality of a test class without subclassing the test. Instead, one can subclass the decorater and use it to wrap the test class.

Does not assume ownership of the test it decorates

## Constructor & Destructor Documentation

CPPUNIT_NS_BEGIN TestCaseDecorator::TestCaseDecorator | ( | TestCase * | test | ) |

TestCaseDecorator::~TestCaseDecorator | ( |  | ) |

## Member Function Documentation

std::string TestCaseDecorator::getName | ( |  | ) | const`[virtual]`

Returns the name of the test case.

Reimplemented from TestCase.

void TestCaseDecorator::setUp | ( |  | ) | `[virtual]`

Set up context before running a test.

Reimplemented from TestFixture.

void TestCaseDecorator::tearDown | ( |  | ) | `[virtual]`

Clean up after the test run.

Reimplemented from TestFixture.

void TestCaseDecorator::runTest | ( |  | ) | `[virtual]`

FIXME: this should probably be pure virtual.

Reimplemented from TestCase.

Reimplemented in ExceptionTestCaseDecorator< ExpectedException >.

## Member Data Documentation

TestCase* TestCaseDecorator::m_test`[protected]`

The documentation for this class was generated from the following files:

- TestCaseDecorator.h
- TestCaseDecorator.cpp

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