summaryrefslogtreecommitdiff
path: root/src/cppunit/TestFailure.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/cppunit/TestFailure.cpp')
-rw-r--r--src/cppunit/TestFailure.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/cppunit/TestFailure.cpp b/src/cppunit/TestFailure.cpp
index 0db1628..51cd8cd 100644
--- a/src/cppunit/TestFailure.cpp
+++ b/src/cppunit/TestFailure.cpp
@@ -36,6 +36,14 @@ TestFailure::thrownException() const
}
+/// Gets the failure location.
+SourceLine
+TestFailure::sourceLine() const
+{
+ return m_thrownException->sourceLine();
+}
+
+
/// Indicates if the failure is a failed assertion or an error.
bool
TestFailure::isError() const
@@ -43,6 +51,15 @@ TestFailure::isError() const
return m_isError;
}
+
+/// Gets the name of the failed test.
+std::string
+TestFailure::failedTestName() const
+{
+ return m_failedTest->getName();
+}
+
+
/// Returns a short description of the failure.
std::string
TestFailure::toString() const