Skip to content

Commit

Permalink
test: exit with code 1 when no fn tests are found
Browse files Browse the repository at this point in the history
Prevents the test_runner from exiting silently with code 0 when no tests were found.
  • Loading branch information
m3dwards committed Mar 6, 2024
1 parent 0fa9f17 commit 33268a8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/functional/test_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ def main():
if not enable_bitcoind:
print("No functional tests to run.")
print("Rerun ./configure with --with-daemon and then make")
sys.exit(0)
sys.exit(1)

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

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

0 comments on commit 33268a8

Please sign in to comment.