Skip to content

Commit 59567d7

Browse files
committed
Merge bitcoin/bitcoin#29576: Update functional test runner to return error code when no tests are found to run
33268a8 test: exit with code 1 when no fn tests are found (Max Edwards) Pull request description: As discussed in the following PR comment: bitcoin/bitcoin#29535 (comment) Prevents the test_runner from exiting silently with code 0 when no tests were found which has recently happened after a GHA runner update such as in this run: https://github.com/bitcoin/bitcoin/actions/runs/8131828989/job/22239779585#step:27:63 ACKs for top commit: TheCharlatan: ACK 33268a8 theStack: lgtm ACK 33268a8 Tree-SHA512: d389e9f5e4da7ce1627fb2fad9b33baf0b04e75dbdbfc0dbf5f1e3e2b0ae1e79721476c5668476055b0f7de29723ed02c8d7e420081a555030cb784886e240fc
2 parents ab5dfdb + 33268a8 commit 59567d7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/functional/test_runner.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ def main():
473473
if not enable_bitcoind:
474474
print("No functional tests to run.")
475475
print("Rerun ./configure with --with-daemon and then make")
476-
sys.exit(0)
476+
sys.exit(1)
477477

478478
# Build list of tests
479479
test_list = []
@@ -522,7 +522,7 @@ def main():
522522
if not test_list:
523523
print("No valid test scripts specified. Check that your test is in one "
524524
"of the test lists in test_runner.py, or run test_runner.py with no arguments to run all tests")
525-
sys.exit(0)
525+
sys.exit(1)
526526

527527
if args.help:
528528
# Print help for test_runner.py, then print help of the first script (with args removed) and exit.

0 commit comments

Comments
 (0)