aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAva Chow <github@achow101.com>2024-09-23 13:02:28 -0400
committerAva Chow <github@achow101.com>2024-09-24 11:40:27 -0400
commite24a25d882ba8c8dacc1eede6b9373fe7601f85b (patch)
tree3f5d5fda1e13d48ece75761467f787226db93888 /src
parent1147e72953d1f262111a4b1d5a438a8394511bc7 (diff)
test: Use shell builtins in run_command test case
Github-Pull: bitcoin/bitcoin#30952 Rebased-From: 7bd3ee62f6d6f59ca599e85f81776d282dee1539
Diffstat (limited to 'src')
-rw-r--r--src/test/system_tests.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/system_tests.cpp b/src/test/system_tests.cpp
index 07d15f5552..c9dd9c82cd 100644
--- a/src/test/system_tests.cpp
+++ b/src/test/system_tests.cpp
@@ -54,7 +54,7 @@ BOOST_AUTO_TEST_CASE(run_command)
}
{
// Return non-zero exit code, with error message for stderr
- const std::string command{"python3 -c 'import sys; print(\"err\", file=sys.stderr); sys.exit(2)'"};
+ const std::string command{"sh -c 'echo err 1>&2 && false'"};
const std::string expected{"err"};
BOOST_CHECK_EXCEPTION(RunCommandParseJSON(command), std::runtime_error, [&](const std::runtime_error& e) {
const std::string what(e.what());