Test Class Referenceabstract

This class represents a test or a suite of tests according to the Composite Pattern. More...

`#include <Test.h>`

Inheritance diagram for Test:

## Public Member Functions

| Test (const string &name)
| Construct a Test with the given name.
virtual | ~Test ()
virtual bool | accept (TestVisitor &visitor)=0
| Makes the visitor visit this object as per the Visitor Pattern.
const string & | getName () const
| Returns the name passed to the constructor.
bool | operator< (const Test &test) const
| Compares names lexicographically.

## Private Attributes

string | _name
| The name passed to the constructor.

## Detailed Description

This class represents a test or a suite of tests according to the Composite Pattern.

The hierarchy of tests can be traversed according to the Visitor Pattern.

Definition at line 29 of file Test.h.

## Constructor & Destructor Documentation

## Test()

Test::Test | ( | const string & | name | ) |

Construct a Test with the given name.

Definition at line 20 of file Test.cpp.

## ~Test()

Test::~Test | ( |  | ) |

virtual

Definition at line 24 of file Test.cpp.

## Member Function Documentation

## accept()

virtual bool Test::accept | ( | TestVisitor & | visitor | ) |

pure virtual

Makes the visitor visit this object as per the Visitor Pattern.

Implemented in TestCase, and TestSuite.

## getName()

const string & Test::getName | ( |  | ) | const

Returns the name passed to the constructor.

Definition at line 27 of file Test.cpp.

## operator<()

bool Test::operator< | ( | const Test & | test | ) | const

Compares names lexicographically.

Definition at line 31 of file Test.cpp.

## Member Data Documentation

## _name

string Test::_name

private

The name passed to the constructor.

Definition at line 48 of file Test.h.

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

- src/test/Test.h
- src/test/Test.cpp