00001
#ifndef CPPUNIT_TEXTOUTPUTTER_H
00002
#define CPPUNIT_TEXTOUTPUTTER_H
00003
00004
#include <cppunit/Portability.h>
00005
#include <cppunit/Outputter.h>
00006
#include <iostream>
00007
00008
CPPUNIT_NS_BEGIN
00009
00010
00011
class Exception;
00012
class SourceLine;
00013
class TestResultCollector;
00014
class TestFailure;
00015
00016
00020 class CPPUNIT_API TextOutputter :
public Outputter
00021 {
00022
public:
00023 TextOutputter(
TestResultCollector *result,
00024 std::ostream &stream );
00025
00027
virtual ~TextOutputter();
00028
00029
void write();
00030
virtual void printFailures();
00031
virtual void printHeader();
00032
00033
virtual void printFailure(
TestFailure *failure,
00034
int failureNumber );
00035
virtual void printFailureListMark(
int failureNumber );
00036
virtual void printFailureTestName(
TestFailure *failure );
00037
virtual void printFailureType(
TestFailure *failure );
00038
virtual void printFailureLocation(
SourceLine sourceLine );
00039
virtual void printFailureDetail(
Exception *thrownException );
00040
virtual void printFailureWarning();
00041
virtual void printStatistics();
00042
00043
protected:
00044 TestResultCollector *m_result;
00045 std::ostream &m_stream;
00046
00047
private:
00049 TextOutputter(
const TextOutputter © );
00050
00052
void operator =(
const TextOutputter © );
00053 };
00054
00055
00056
00057
CPPUNIT_NS_END
00058
00059
#endif // CPPUNIT_TEXTOUTPUTTER_H