From 0189fa3aac1ecf6ac8542bc4a1fe09dd3439ab00 Mon Sep 17 00:00:00 2001 From: Egor Krugletsov Date: Sat, 28 Sep 2024 20:11:30 +0300 Subject: [PATCH] Compatibility changes with Catch2 3.7.1 --- config/catch/CatchFakeit.hpp | 8 ++++---- single_header/catch/fakeit.hpp | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/config/catch/CatchFakeit.hpp b/config/catch/CatchFakeit.hpp index 104cfce7..616a369d 100644 --- a/config/catch/CatchFakeit.hpp +++ b/config/catch/CatchFakeit.hpp @@ -49,18 +49,18 @@ namespace fakeit { INTERNAL_CATCH_TRY { \ CATCH_INTERNAL_START_WARNINGS_SUPPRESSION \ CATCH_INTERNAL_SUPPRESS_PARENTHESES_WARNINGS \ - catchAssertionHandler.handleMessage(resultWas, fomattedMessage); \ + catchAssertionHandler.handleMessage(resultWas, std::move(fomattedMessage)); \ CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION \ } INTERNAL_CATCH_CATCH(catchAssertionHandler) { \ - INTERNAL_CATCH_REACT(catchAssertionHandler) \ + catchAssertionHandler.complete(); \ } #else INTERNAL_CATCH_TRY { \ CATCH_INTERNAL_SUPPRESS_PARENTHESES_WARNINGS \ - catchAssertionHandler.handleMessage(resultWas, fomattedMessage); \ + catchAssertionHandler.handleMessage(resultWas, std::move(fomattedMessage)); \ CATCH_INTERNAL_UNSUPPRESS_PARENTHESES_WARNINGS \ } INTERNAL_CATCH_CATCH(catchAssertionHandler) { \ - INTERNAL_CATCH_REACT(catchAssertionHandler) \ + catchAssertionHandler.complete(); \ } #endif } diff --git a/single_header/catch/fakeit.hpp b/single_header/catch/fakeit.hpp index 90468539..ab02fcf0 100644 --- a/single_header/catch/fakeit.hpp +++ b/single_header/catch/fakeit.hpp @@ -1207,18 +1207,18 @@ namespace fakeit { INTERNAL_CATCH_TRY { \ CATCH_INTERNAL_START_WARNINGS_SUPPRESSION \ CATCH_INTERNAL_SUPPRESS_PARENTHESES_WARNINGS \ - catchAssertionHandler.handleMessage(resultWas, fomattedMessage); \ + catchAssertionHandler.handleMessage(resultWas, std::move(fomattedMessage); \ CATCH_INTERNAL_STOP_WARNINGS_SUPPRESSION \ } INTERNAL_CATCH_CATCH(catchAssertionHandler) { \ - INTERNAL_CATCH_REACT(catchAssertionHandler) \ + catchAssertionHandler.complete(); \ } #else INTERNAL_CATCH_TRY { \ CATCH_INTERNAL_SUPPRESS_PARENTHESES_WARNINGS \ - catchAssertionHandler.handleMessage(resultWas, fomattedMessage); \ + catchAssertionHandler.handleMessage(resultWas, std::move(fomattedMessage)); \ CATCH_INTERNAL_UNSUPPRESS_PARENTHESES_WARNINGS \ } INTERNAL_CATCH_CATCH(catchAssertionHandler) { \ - INTERNAL_CATCH_REACT(catchAssertionHandler) \ + catchAssertionHandler.complete(); \ } #endif }