Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorMartin Hořeňovský2024-09-15 20:46:24 +0200
committerMartin Hořeňovský2024-09-15 20:46:24 +0200
commit432695291a0722e9b00c0a76ef2f27b61144506a (patch)
treeee09afd8d7b1969d95de0d4f1f74922175f1c5c1
parente63f3cc817eff4c67b59c19d5299ef402ffdf4ed (diff)
downloadcatch3-devel-piped-redirect.tar.gz
Flush AND sleepdevel-piped-redirect
-rw-r--r--tests/SelfTest/UsageTests/Tricky.tests.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/SelfTest/UsageTests/Tricky.tests.cpp b/tests/SelfTest/UsageTests/Tricky.tests.cpp
index 041d7867..edb41f81 100644
--- a/tests/SelfTest/UsageTests/Tricky.tests.cpp
+++ b/tests/SelfTest/UsageTests/Tricky.tests.cpp
@@ -308,10 +308,15 @@ TEST_CASE( "X/level/0/b", "[Tricky][fizz]" ){ SUCCEED(""); }
TEST_CASE( "X/level/1/a", "[Tricky]" ) { SUCCEED(""); }
TEST_CASE( "X/level/1/b", "[Tricky]" ) { SUCCEED(""); }
+#include <chrono>
+#include <thread>
+
TEST_CASE( "has printf" ) {
// This can cause problems as, currently, stdout itself is not redirected - only the cout (and cerr) buffer
printf( "loose text artifact\n" );
+ fflush( stdout );
+ std::this_thread::sleep_for( std::chrono::seconds( 1 ) );
}
namespace {