Progmasoft Git

catch3

Progmasoft Catch3: an independently maintained C++17 test framework with a parallel runner, property checks, snapshots and structured results.

Clonegit clone https://git.progmasoft.com/catch3

Fix teamcity reporter compilation with single header

Commit
a3632facf3b425b042ab36d0965fbe2900fc9bea
Author
Martin Hořeňovský ·
Parents
7d0db6b8e9f0

Files · Download .tar.gz

Changes

 include/reporters/catch_reporter_teamcity.hpp | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/include/reporters/catch_reporter_teamcity.hpp b/include/reporters/catch_reporter_teamcity.hpp
index 96e35a84..dbd0db53 100644
--- a/include/reporters/catch_reporter_teamcity.hpp
+++ b/include/reporters/catch_reporter_teamcity.hpp
@@ -14,8 +14,6 @@
 // file can be distributed as a single header that works with the main
 // Catch single header.
 
-#include "../internal/catch_enforce.h"
-
 #include <cstring>
 
 #ifdef __clang__
@@ -99,12 +97,12 @@ namespace Catch {
                     case ResultWas::Ok:
                     case ResultWas::Info:
                     case ResultWas::Warning:
-                        CATCH_ERROR( "Internal error in TeamCity reporter" );
+                        throw std::domain_error( "Internal error in TeamCity reporter" );
                     // These cases are here to prevent compiler warnings
                     case ResultWas::Unknown:
                     case ResultWas::FailureBit:
                     case ResultWas::Exception:
-                        CATCH_ERROR( "Not implemented" );
+                        throw std::domain_error( "Not implemented" );
                 }
                 if( assertionStats.infoMessages.size() == 1 )
                     msg << " with message:";