diff options
| author | Phil Nash | 2013-04-08 12:05:32 +0100 |
|---|---|---|
| committer | Phil Nash | 2013-04-08 12:05:32 +0100 |
| commit | 3bd42417952e5065cd1ccebc1d6cdd0dbe6c4812 (patch) | |
| tree | ea8d667cd2b4e002acb2185677600862dc588274 /include | |
| parent | 8764177c0e85512f3f0315c67b7a52fa6d8c6423 (diff) | |
| download | catch3-3bd42417952e5065cd1ccebc1d6cdd0dbe6c4812.tar.gz | |
Fixed Junit issue with REQUIRE_THROWS
- As mentioned by @SebDyn in GitHub issue #5
Diffstat (limited to 'include')
| -rw-r--r-- | include/reporters/catch_reporter_console.hpp | 10 | ||||
| -rw-r--r-- | include/reporters/catch_reporter_junit.hpp | 6 |
2 files changed, 6 insertions, 10 deletions
diff --git a/include/reporters/catch_reporter_console.hpp b/include/reporters/catch_reporter_console.hpp index cb50436d..9cd25e89 100644 --- a/include/reporters/catch_reporter_console.hpp +++ b/include/reporters/catch_reporter_console.hpp @@ -155,18 +155,10 @@ namespace Catch { if( _stats.infoMessages.size() > 1 ) messageLabel = "explicitly with messages"; break; - case ResultWas::Exception: - passOrFail = "FAILED"; - colour = Colour::Error; - if( _stats.infoMessages.size() == 1 ) - messageLabel = "with message"; - if( _stats.infoMessages.size() > 1 ) - messageLabel = "with messages"; - break; - // These cases are here to prevent compiler warnings case ResultWas::Unknown: case ResultWas::FailureBit: + case ResultWas::Exception: passOrFail = "** internal error **"; colour = Colour::Error; break; diff --git a/include/reporters/catch_reporter_junit.hpp b/include/reporters/catch_reporter_junit.hpp index af43b3b7..7e2f4b2b 100644 --- a/include/reporters/catch_reporter_junit.hpp +++ b/include/reporters/catch_reporter_junit.hpp @@ -143,10 +143,14 @@ namespace Catch { case ResultWas::Ok: stats.m_element = "success"; break; + case ResultWas::DidntThrowException: + stats.m_element = "failure"; + m_currentStats->m_failuresCount++; + break; case ResultWas::Unknown: case ResultWas::FailureBit: case ResultWas::Exception: - case ResultWas::DidntThrowException: + stats.m_element = "* internal error *"; break; } testCaseStats.m_testStats.push_back( stats ); |