Skip to content

Commit

Permalink
Run all tests if have no specified tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tesuji committed Jul 31, 2020
1 parent c058a8b commit a475722
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/etc/test-float-parse/runtests.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,10 +193,12 @@ def interact(proc, queue):

def main():
global MAILBOX
tests = [os.path.splitext(f)[0] for f in glob('*.rs')
if not f.startswith('_')]
all_tests = [os.path.splitext(f)[0] for f in glob('*.rs') if not f.startswith('_')]
args = sys.argv[1:]
tests = [test for test in tests if test in args]
if args:
tests = [test for test in all_tests if test in args]
else
tests = all_tests
if not tests:
print("Error: No tests to run")
sys.exit(1)
Expand Down

0 comments on commit a475722

Please sign in to comment.