mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-04 02:02:42 +02:00
Merge bitcoin/bitcoin#34791: test: Suppress another unsolicited mock_process/* output
a1f22a0a6btest: Suppress another unsolicited `mock_process/*` output (Hennadii Stepanov) Pull request description: This is a follow-up to https://github.com/bitcoin/bitcoin/pull/33929. The[ `mock_process/*`](390e7d61bd/src/test/mock_process.cpp (L10)) test cases, which serve as helpers for [`system_tests`](390e7d61bd/src/test/system_tests.cpp (L23)) 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 PR handles this specific case and documents the other suppressions. ACKs for top commit: maflcko: lgtm ACKa1f22a0a6bsedited: ACKa1f22a0a6bTree-SHA512: 480f0f74ce50b6fb315bfeb6f6d3a4a4791557a6177aa995197c002bf871f878573df0f313344206f82e4d54c7a62d7cea2fdcb8cd96475b4b6cc7d4ffaf0538
This commit is contained in:
@@ -26,7 +26,18 @@ BOOST_FIXTURE_TEST_SUITE(system_tests, BasicTestingSetup)
|
||||
|
||||
static std::vector<std::string> 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)
|
||||
|
||||
Reference in New Issue
Block a user