CppUnit project page FAQ

TestFailure.h
Go to the documentation of this file.
1 #ifndef CPPUNIT_TESTFAILURE_H // -*- C++ -*-
2 #define CPPUNIT_TESTFAILURE_H
3 
4 #include <cppunit/Portability.h>
5 #include <string>
6 
8 
9 
10 class Exception;
11 class SourceLine;
12 class Test;
13 
14 
25 {
26 public:
27  TestFailure( Test *failedTest,
28  Exception *thrownException,
29  bool isError );
30 
31  virtual ~TestFailure ();
32 
33  virtual Test *failedTest() const;
34 
35  virtual Exception *thrownException() const;
36 
37  virtual SourceLine sourceLine() const;
38 
39  virtual bool isError() const;
40 
41  virtual std::string failedTestName() const;
42 
43  virtual TestFailure *clone() const;
44 
45 protected:
48  bool m_isError;
49 
50 private:
51  TestFailure( const TestFailure &other );
52  TestFailure &operator =( const TestFailure& other );
53 };
54 
55 
57 
58 #endif // CPPUNIT_TESTFAILURE_H
#define CPPUNIT_API
Definition: CppUnitApi.h:27
#define CPPUNIT_NS_END
Definition: Portability.h:106
#define CPPUNIT_NS_BEGIN
Definition: Portability.h:105
Exceptions thrown by failed assertions.
Definition: Exception.h:20
Represents a source line location.
Definition: SourceLine.h:31
Record of a failed Test execution.
Definition: TestFailure.h:25
Test * m_failedTest
Definition: TestFailure.h:46
Exception * m_thrownException
Definition: TestFailure.h:47
bool m_isError
Definition: TestFailure.h:48
TestFailure(const TestFailure &other)
Base class for all test objects.
Definition: Test.h:26

Send comments to:
CppUnit Developers