From a1f22a0a6b98f7cbd0d62729dad9ce7d67974f7e Mon Sep 17 00:00:00 2001 From: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> Date: Fri, 13 Mar 2026 11:29:53 +0000 Subject: [PATCH] test: Suppress another unsolicited `mock_process/*` output The `mock_process/*` test cases, which serve as helpers for `system_tests` rather than actual tests, are invoked in a way that suppresses unsolicited output to stdout or stderr to keep the test results reproducible. However, in debug builds, the Windows CRT still prints false-positive memory leak dumps to stderr. This change handles this specific case and documents the other suppressions. --- src/test/system_tests.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/test/system_tests.cpp b/src/test/system_tests.cpp index bd57661b051c..408666d67089 100644 --- a/src/test/system_tests.cpp +++ b/src/test/system_tests.cpp @@ -26,7 +26,18 @@ BOOST_FIXTURE_TEST_SUITE(system_tests, BasicTestingSetup) static std::vector mock_executable(std::string name) { - return {boost::unit_test::framework::master_test_suite().argv[0], "--log_level=nothing", "--report_level=no", "--run_test=mock_process/" + name}; + // Invoke the mock_process/* test case with all unsolicited output suppressed. + return { + boost::unit_test::framework::master_test_suite().argv[0], + // Disable false-positive memory leak dumps to stderr + // in debug builds when using the Windows UCRT. + "--detect_memory_leaks=0", + // Disable logging to stdout. + "--log_level=nothing", + // Disable the test report to stderr. + "--report_level=no", + "--run_test=mock_process/" + name, + }; } BOOST_AUTO_TEST_CASE(run_command)