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

Output option description lines that don't end in newline

Commit
dae5808666b3561e7e0da0fde091459fd8b7602f
Author
Phil Nash ·
Parents
e2d215e9c071

Files · Download .tar.gz

Changes

 include/catch_runner.hpp | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/include/catch_runner.hpp b/include/catch_runner.hpp
index 2f82519b..e0c7b34e 100644
--- a/include/catch_runner.hpp
+++ b/include/catch_runner.hpp
@@ -183,6 +183,7 @@ namespace Catch {
         addIndent( os, indent );
         os << paragraph << "\n";
     }
+
     inline std::string addLineBreaks( const std::string& str, std::size_t columns, std::size_t indent = 0 ) {
         std::ostringstream oss;
         std::string::size_type pos = 0;
@@ -193,6 +194,9 @@ namespace Catch {
             pos = newline+1;
             newline = str.find_first_of( '\n', pos );
         }
+        if( pos != str.size() )
+            recursivelyWrapLine( oss, str.substr( pos, str.size()-pos ), columns, indent );
+
         return oss.str();
     }